[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Feature Request: ls --no-sym-destinations
From: |
Bob Proulx |
Subject: |
Re: Feature Request: ls --no-sym-destinations |
Date: |
Fri, 15 Nov 2013 18:43:05 -0700 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Brian Nash wrote:
> I recently noticed that someone on IRC was looking for a way to use
> `ls -la' without the destination of symlinks clogging up the
> output. I believe this would be an excellent feature to include in
> the coreutils package. It would also (theoretically) be an easy
> addition.
Already there. Try the -L option.
`-L'
`--dereference'
When showing file information for a symbolic link, show information
for the file the link references rather than the link itself.
However, even with this option, `ls' still prints the name of the
link itself, not the name of the file that the link points to.
$ ls -laog
total 8
drwxrwxr-x 2 4096 Dec 16 2011 ./
drwxrwxr-x 4 4096 Dec 16 2011 ../
lrwxrwxrwx 1 17 Dec 16 2011 link1 -> ../dir1/datestamp
lrwxrwxrwx 1 7 Dec 16 2011 linkdir2 -> ../dir1
$ ls -laog -L
total 16
drwxrwxr-x 2 4096 Dec 16 2011 ./
drwxrwxr-x 4 4096 Dec 16 2011 ../
-rw-r--r-- 1 29 Dec 16 2011 link1
drwxrwxr-x 2 4096 Dec 16 2011 linkdir2
Bob