# restic(1) ## Create new snapshot repository ```bash # Create a local backup repository. restic -r init # Create a backup repository on a remote host. restic -r sftp:user@host: init ``` ## Example: Restore file pattern from `latest` snapshot Restore files matching `` from the `latest` snapshot (pseudo snapshot ID) into ``. ```bash restic -r restore -i --target latest ``` ## Mount snapshots Mount snapshots as user filesystem (fuse) to given mount point. ```bash restic -r mount # Mounted snapshots can be limited by host. restic -r mount --host # Mounted snapshots can be limited by path (abs path). restic -r mount --path ``` ## Repository maintenance Check the repository for errors and report them. ```bash restic -r check ``` Check the repository for non-referenced data and remove it. ```bash restic -r prune ``` ## References - [`restic` read the docs][restic] - [sftp][restic-sftp] [restic]: https://restic.readthedocs.io/en/stable/index.html [restic-sftp]: https://restic.readthedocs.io/en/stable/030_preparing_a_new_repo.html#sftp