svn switches


To use the command-line client, type svn, followed by the subcommand, and any switches or targets that you wish to operate on. Software Configuration Management has different switches for its subcommands. However, they carry the same action regardless of the subcommand you use it with. Below is a list of switches you can use and a brief description of the function each performs.

Enable auto-props, overriding the enable-auto-props directive in the config file.
--config-dir DIR
Instructs Subversion to read configuration information from the specified directory.
--diff-cmd CMD
Specifies an external program to show differences between files.
--diff3-cmd CMD
Specifies an external program to merge files.
Goes through all the motions of running a command, however makes no actual changes (on your local working copy or in the repository.
--editor-cmd CMD
Specifies an external program to edit a log message or a property value.
--encoding ENC
Specifies the encoding (if your commit message is in any other encoding).
--extensions (-x) ARGS
Specifies an argument/s that Subversion should pass to an external diff command when providing differences between files. This switch can only be provided you first pass the --diff-cmd switch.
--file (-F) FILENAME
Specifies the name of a file as a target for a subcommand.
Forces a particular command or operation to run.
Forces a suspicious parameter passed to the --message (-m) or --file (-F) options to be accepted as valid. By default, Subversion will produce an error if parameters to these options look like they might instead be targets of the subcommand. For example, if you pass a versioned file's path to the --file (-F) option, Subversion will assume you've made a mistake, that the path was instead intended as the target of the operation, and that you simply failed to provide some other­unversioned­file as the source of your log message. To assert your intent and override these types of errors, pass the --force-log option to commands that accept log messages.
--help (-h, -?)
Shows the built-in help text for each specified subcommand. If used alone, it displays the general svn client help text.
Ignore ancestry when calculating differences (rely on path contents alone).
Prints output in a format suitable for concatenation.
--message (-m) MESSAGE
Indicates that you will specify a commit message on the command line
--new ARG
Uses ARG as the newer target.
Prevents caching of authentication information (e.g. username and password) in the Subversion administrative directories.
Disable auto-props, overriding the enable-auto-props directive in the config file.
Prevents Subversion from printing differences for deleted files.
Shows files in the status listing that would normally be omitted since they match a pattern in the svn:ignore property.
Prevents prompting for credentials (e.g. username or password) in the case of an authentication failure.
--non-recursive (-N)
Stops a subcommand from recursing into subdirectories.
Takes ancestry into consideration when calculating differences.
--old ARG
Uses ARG as the older target.
--password PASS
Indicates that you are providing your password for authentication on the command line.
--quiet (-q)
Requests that the client print only essential information while performing an operation or giving an output.
--recursive (-R)
Makes a subcommand recurse into subdirectories. Most subcommands recurse by default.
--relocate FROM TO [PATH...]
Used with the svn switch subcommand, changes the location of the repository that your working copy references. This is useful if the location of your repository changes and you have an existing working copy that you'd like to continue to use.
--revision (-r) REV
Indicates that you're going to provide a revision (or range of revisions) for a particular operation. You can provide revision numbers, revision keywords or dates (in curly braces), as arguments to the revision switch. If you wish to provide a range of revisions, you can provide two revisions separated by a colon.
Operates on a revision property specific to a file or directory. This switch requires you to pass a revision with the --revision (-r) switch.
--show-updates (-u)
Displays information about the obsolete files in your working copy. It does not update any of your files but just shows you which files are scheduled to be updated if you run svn update.
Stops a subcommand from storing historical information when a copy is encountered.
Causes Subversion to use strict semantics.
--targets FILENAME
Gets the list of files from the filename you provide instead of listing all the files on the command line.
--username NAME
Indicates that you are providing your username for authentication on the command line.
--verbose (-v)
Prints out as much information as possible while running any subcommand.
Prints the client version info.
Prints output in XML format.