|Perl: the Markov chain saw|
Re^4: Directory Separator (none)by vsespb (Chaplain)
|on May 28, 2013 at 23:39 UTC||Need Help??|
rsync, for one, disagrees
A trailing slash on the source changes this behavior to avoid creating an additional directory level at the destination. You can think of a trailing / on a source as meaning “copy the contents of this directory” as opposed to “copy the directory by name”But here we see that leading '/' sometimes does not mean root
if the pattern starts with a / then it is matched against the start of the filename, otherwise it is matched against the end of the filename.
Thus “/foo” would match a file called “foo” at the transfer-root (see above for how this is different from the filesystem-root).
I think filename is filename. It points to file. When you passing arguments to command line programs - it's different thing - sometimes you need special syntax, depending on what you want to do"mv foo bar/" is only the same as "mv foo bar" if you are 100% sure that bar already exists and is a directory.
yep, but there are problems when it's symlink to a directory example
In the usual case, dirname() returns the string up to, but not including, the final '/'