Re: ln -s example

2012-09-20 Thread Amit Kulkarni
  shouldn't this order be flipped?
 

 the example does what its description says. why do you think it should
 be reversed?

 because people are often confused by symlinks? I always tell the
 confused: the order is the same as cp(1): the first argument needs to
 exits, the second one is created.

 -Otto

This is very helpful. Usually in OpenBSD, you create a symbolic link
/var/www which has limited space and have it point to /home/www where
actual data is stored and which has more space.

This particular example could be

Create a symbolic link named /var/www and point it to /home/www:

 # ln -s /home/www /var/www



Re: ln -s example

2012-09-20 Thread Ian Darwin

On 12-09-20 8:34 AM, Amit Kulkarni wrote:

This is very helpful. Usually in OpenBSD, you create a symbolic link
/var/www which has limited space and have it point to /home/www where
actual data is stored and which has more space.

This particular example could be

Create a symbolic link named /var/www and point it to /home/www:

  # ln -s /home/www /var/www



A good example is one that actually works.

Since /var/www exists in the default configuration on OpenBSD, your example
will create a symlink in the real /var/ww called www, pointing to 
/home/www, and will never get used.


$ sudo ln -s /home/www /var/www
$ ls -l /var/www/www
lrwxr-xr-x  1 root  daemon  9 Sep 20 12:36 /var/www/www - /home/www
$

To make it work, you'd have to explain the rationale, show the command 
for moving
the contents (bikeshed warning!), then rmdir /var/www, and finally do 
your symlink.


It's not worth it. Pick a simpler example.



ln -s example

2012-09-19 Thread Amit Kulkarni
shouldn't this order be flipped?

Index: ln.1
===
RCS file: /cvs/src/bin/ln/ln.1,v
retrieving revision 1.29
diff -u -p -r1.29 ln.1
--- ln.12 Mar 2011 07:47:21 -   1.29
+++ ln.119 Sep 2012 23:27:04 -
@@ -130,7 +130,7 @@ Create a symbolic link named
 and point it to
 .Pa /var/www :
 .Pp
-.Dl # ln -s /var/www /home/www
+.Dl # ln -s /home/www /var/www
 .Pp
 Hard link
 .Pa /usr/local/bin/fooprog



Re: ln -s example

2012-09-19 Thread Chris Cappuccio
Amit Kulkarni [amitk...@gmail.com] wrote:
 shouldn't this order be flipped?
 

If you wanted a link in /var/www/www back to /home/www, then yes, it should be 
flipped.

 Index: ln.1
 ===
 RCS file: /cvs/src/bin/ln/ln.1,v
 retrieving revision 1.29
 diff -u -p -r1.29 ln.1
 --- ln.1  2 Mar 2011 07:47:21 -   1.29
 +++ ln.1  19 Sep 2012 23:27:04 -
 @@ -130,7 +130,7 @@ Create a symbolic link named
  and point it to
  .Pa /var/www :
  .Pp
 -.Dl # ln -s /var/www /home/www
 +.Dl # ln -s /home/www /var/www
  .Pp
  Hard link
  .Pa /usr/local/bin/fooprog

-- 
Keep them laughing half the time, scared of you the other half. And always keep 
them guessing. -- Clair George