Is there a command that will print the file path in the repo browser on the command line?

Is there a command that will print the file path in the repo browser on the command line?

SVN diff prints only the file name.

Thanks.

+5
source share
2 answers
svn info path/to/filename

will show you some pieces of information. The ones you are looking for are the URL and the root directory of the repository:

$ svn info mydialog.h
[...]
URL: http://svn.server.net/my-repo/trunk/ui/mydialog.h
Repository Root: http://svn.server.net/my-repo
[...]

URL is the absolute position of the file, and Ropository Root is the base URL of the repository. The URL always starts with the address of the root of the repository, so if you crop the root repository from the beginning of the URL, you will be left with the relative position of the file inside the repository. In this case, it is

/trunk/ui/mydialog.h
+7
source

svn info?

+3
source

All Articles