doc: restore: explain explicitly effect of specifying snapshot:subfolder

The effect could be read from the examples, but it was easy to miss.
This commit is contained in:
Kjetil Torgrim Homme
2025-12-05 17:50:53 +01:00
parent 9e2d60e28c
commit 0673b58d7c
+4 -2
View File
@@ -50,7 +50,9 @@ This will restore the file ``foo`` to ``/tmp/restore-work/work/foo``.
To only restore a specific subfolder, you can use the ``<snapshot>:<subfolder>``
syntax, where ``snapshot`` is the ID of a snapshot (or the string ``latest``)
and ``subfolder`` is a path within the snapshot.
and ``subfolder`` is a path within the snapshot. This changes the root for the
arguments to ``--include`` or ``--exclude``, they should be specified relative
to ``subfolder``.
.. code-block:: console
@@ -58,7 +60,7 @@ and ``subfolder`` is a path within the snapshot.
enter password for repository:
restoring <Snapshot of [/home/user/work] at 2015-05-08 21:40:19.884408621 +0200 CEST> to /tmp/restore-work
This will restore the file ``foo`` to ``/tmp/restore-work/foo``.
This will restore the file ``/work/foo`` to ``/tmp/restore-work/foo``.
You can use the command ``restic ls latest`` or ``restic find foo`` to find the
path to the file within the snapshot. This path you can then pass to