[cs631apue] Question about ~ translation 2
sshah83
sshah83 at stevens.edu
Sat Nov 22 18:04:51 EST 2014
Professor,
Thanks for the clarification. Just want to clarify one thing:
the specification (man page) says "~ is translated into that user’s sws
directory (ie /home/<user>/sws/ )"
So in the examples you provided shouldn't it be :
/~foo/foo/f <foo's home directory>/sws/foo/f
thanks
Sonal
On 11/22/2014 3:50 PM, Jan Schaumann wrote:
> zding4 <zding4 at stevens.edu> wrote:
>
>> There must be a user name followed by `~` like
>> `server/~username/somefile`
>> Can `~` exist without the user name? like:
>> `server/~/somefile`
>
> Neither of these would yield expansion of '~' and both would be literal
> pathnames. (They'd both also be invalid, since they're missing a
> leading '/'.)
>
> A few examples:
>
> URI absolute path
> ---------------------------------------------
> / <docroot>/.
> /foo <docroot>/foo
> /~foo <foo's home directory>/
> /~foo/foo/f <foo's home directory>/foo/f
> /foo/~foo/f <docroot>/foo/~foo/f
> ~foo 400 Bad Request
> /cgi-bin/foo <cgidir>/foo
>
> I hope this helps.
>
> -Jan
> _______________________________________________
> cs631apue mailing list
> cs631apue at lists.stevens.edu
> https://lists.stevens.edu/mailman/listinfo/cs631apue
More information about the cs631apue
mailing list