tags:

views:

74

answers:

2

Example Mercurial URL: ssh://myhost//path/to/repo

Why two slashes? The hostname is already specified. Why it does not work like http://myhost/path/to/page where only one slash is sufficient?

+7  A: 

See this url, which says this:

path is relative to the remote user's home directory by default. Use an extra slash at the start of a path to specify an absolute path:

Thanatos
+3  A: 

Usually a URL is formed in the following way: scheme://user@host:port/path, with the user@ and :port part being optional. This means the first / is the separator between the host part and the path part: it is not part of the path.

Then the path can either be absolute (starts with a /) or relative to the home directory of the user (no /).

This is just a reminder that the paths used by rsync or scp are not urls.

tonfa