Re: pregunta acerca de ls

Alf Delgado Helleseter <[email protected]>
Newsgroups gmane.org.user-groups.linux.gulcr
Message-ID <[email protected]>
On Thu, 13 Oct 2005, "Elídier Moya R." wrote:
>
> Me gustaría que ls -l me presentara la ruta completa de los archivos, 
> quiero decir

No sé cómo hacer eso, pero:

alf@alpha:~$ ls -l /mnt/floppy/
total 3968
-rw-r--r--  1  500 users 3393930 Jun 15 14:16 INITRD
-rw-r--r--  1  500 users   15368 Jun 15 14:16 ISOLINUX.BIN
-rw-r--r--  1  500 users      76 Jun 15 14:16 ISOLINUX.CFG
-rw-r--r--  1 root root   650672 Jun 15 14:07 LINUX
-r--r--r--  1  500 users    2048 Jun 15 14:16 boot.catalog
alf@alpha:~$ ls -l /mnt/floppy/*
-rw-r--r--  1  500 users 3393930 Jun 15 14:16 /mnt/floppy/INITRD
-rw-r--r--  1  500 users   15368 Jun 15 14:16 /mnt/floppy/ISOLINUX.BIN
-rw-r--r--  1  500 users      76 Jun 15 14:16 /mnt/floppy/ISOLINUX.CFG
-rw-r--r--  1 root root   650672 Jun 15 14:07 /mnt/floppy/LINUX
-r--r--r--  1  500 users    2048 Jun 15 14:16 /mnt/floppy/boot.catalog

Tal vez te sirva de algo. Algo como:

alias lspath="ls -ld \${PWD}/*"

haría que:

alf@alpha:/mnt$ lspath
drwxr-xr-x   2 alf  root  1024 Mar 16  2002 /mnt/cdrom/
drwxrwxrwt   4 alf  root  4096 May 14  2004 /mnt/dividi/
dr-xr-xr-x   2  500 users 2048 Jun 15 14:16 /mnt/floppy/
drwxr-xr-x   2 root root  1024 Mar 16  2002 /mnt/hd/
drwxr-xr-x   2 root root  1024 Sep 24  2004 /mnt/llave/
drwxr-xr-x   3 root root  4096 Oct 11 16:14 /mnt/simulador/
drwxr-xr-x  19 root root  4096 May  3 13:42 /mnt/smallslack/
drwxr-xr-x   2 root root  1024 Feb 12  2004 /mnt/var/

pero no sabe cómo manejar cosas como:

lspath /etc

que imprimiría la entrada de directorio de etc

drwxr-xr-x  58 root root  4096 Oct 13 16:19 /etc//

seguida del listado del directorio actual.

A medio camino entre una y otra idea posiblemente encontrarás algo que cumpla 
con tus necesidades.

Saludos,

-alf

______________________________________
         _  ___
    ___ | || | '  Complexity is human
   <_> || || |-    simplicity, divine
   <___||_||_|        SLACKWARE LINUX
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.