Name

svk revert — Undo all local edits.

Synopsis

svk revert PATH...

Description

Reverts any local changes to a file or directory and
resolves any conflicted states. svk
revert will not only revert the contents of an
item in your working copy, but also any property
changes. Finally, you can use it to undo any scheduling
operations that you may have done (e.g. files scheduled
for addition or deletion can be
“unscheduled”).

Alternate Names

None

Changes

Working copy

Accesses Depot

Yes

Accesses Mirrored Repository

No

Switches

--recursive (-R)
--quiet (-q)

Examples

Discard changes to a file:

$ svk revert integer.c
Reverted integer.c

If you want to revert a whole directory of files,
use the --recursive flag:

Note

If you provide no targets to svk
revert, it will do nothing—to protect
you from accidentally losing changes in your working
copy, svk revert requires you to
provide at least one target. ##TODO Sadly currently this
is not true and the svk revert actually
defaults to . if no path is
given.

Tip

You can use svk revert --recursive together with svk
checkout --non-recursive to create a sparse working copy
tree. Lets say you have a project called multi with 4
subdirectories and you only need the p1 and p2
subdirectories. To do so you could run: