ls Top Level

ls

  1. Quick and Concise Document

  2. Beginners

ls QCD Help

 Command       Description
 -------       -----------
 ls            Display files located in the current directory.

 ls *string*   List those files that contain a particular 
               "search-string".

 ls -a         List all files including hidden files that begin 
               with a "." (dot).

 ls -s         List the size of all files.

 ls -F         Identify the file type of all files, placing a 
               "/" after directories.

 ls -la        Provide a long listing of information about all files.

 ls -asR       List all files, including "." files, and their size 
               in a recursive listing through all subdirectories.


ls Beginner Help


Use the ls command to display the files located in the current directory.

   world%  ls

To display only those files whose names contain a particular search string,
use ls with wildcards (*), where "search-string" is replaced with a
string of characters:

   world%  ls *search-string*

To display all files in a directory, both visible and invisible, use
the -a option.  Files that are preceded by a period are normally
invisible, meaning they are not normally displayed when using ls.
These files are often called dot files and are initialization files
for the various programs. 

   world%  ls -a
   .login       
   .cshrc       
   .newsrc      
   .mailrc
   schedule.txt
   program.c
   mailbox

Use the -s option to list the file size of all the files in the current
directory.

   world%  ls -s
   1 activists.dir
   2 chinese.food.brookline
   12 emacs-command-summary
   1 fun.internet.dir
   27 Internet.books.list

Use the -F option to list the file type of all the files in the current
directory.  Filenames followed by a "/" indicate directories.

   world%  ls -F
   ACT_V.Macbeth                   
   Cyberspace.discussion                             
   News/
   Alt.Internet.services
   Mail/


Use the -la option to view a long listing of information about the
files in the current directory.  The long listing includes file
protections, file size, and date last edited.

   world%  ls -la
   -rw-rw-r--    1 freduser freduser     371 Jul 27  1993 .login
   -rw-rw-r--    1 freduser freduser     729 Mar 17 23:07 .cshrc
   -rw-r-----    1 freduser freduser    1558 Apr 17 12:43 sallys.humor
   -rw-r-----    1 freduser freduser    9441 Mar 24 15:54 wired.info


The command ls -asR lists all of your files, including ``.''
files (-a) and their size (-s), in a recursive (-R) listing through
all of your subdirectories.  This is a useful command for identifying
those files that are causing you to exceed your disk quota, and that
need to be removed.

For example:

   world%  ls -asR
   total 967
    1 .               1 .login        16 .pinerc      1 News
   31 ..              1 .msgsrc        1 .tin         1 humor
    2 .cshrc        478 .newsrc        1 Mail         1 mail

   ./.tin:
   total 430
    1 .              1 .index       414 active         0 posted
    1 ..             1 .mailidx       2 attributes    10 tinrc

   ./mail:
   total 2
    1 .                  0 saved-messages 
    1 ..                 0 sent-mail



HOME Top of Help Desk Eye On The World  The World Kiosk


             For further assistance, please send an email 
                   request to support@world.std.com

        Copyright 1995 Software Tool & Die, Inc.  All Rights Reserved.

   Software Tool & Die, Inc., 1330 Beacon St. Suite 215 Brookline, MA 02146