488891
97
Zoom out
Zoom in
Previous page
1/178
Next page
Also keep this in mind for commands to delete objects. Before entering a command
like rm (without any option) for removing a le, you should know if you really want
to get rid of the object: it will be deleted irretrievably, without conrmation.
7.2.1 Using Commands without Options
In Section 6.3.1, Permissions for User, Group and Others” (page 82) you already
got to know one of the most basic commands: ls, which used to list the contents of
a directory. This command can be used with or without options. Entering the plain
ls command shows the contents of the current directory:
tux@knox:~> ls
bin Desktop Documents public_html tux.txt
tux@knox:~>
As you already learned in Section 6.2.1, “Key Features” (page 75) les in Linux may
have a le extension or a sux, such as .txt, but do not need to have one. This
makes it dicult to dierentiate between les and folders in this output of the ls.
By default, the colors in the Bash shell give you a hint: directories are usually shown
in blue, les in black.
7.2.2 Using Commands with Options
A better way to get more details about the contents of a directory is using the ls
command with a string of options. Options modify the way a command works so that
you can get it to carry out specic tasks. Options are separated from the command
with a blank and are usually prexed with a hyphen. The ls -l command shows the
contents of the same directory in full detail (long listing format):
tux@knox:~> ls -l
drwxr-xr-x 1 tux users 48 2006-06-23 16:08 bin
drwx---r-- 1 tux users 53279 2006-06-21 13:16 Desktop
drwx------ 1 tux users 280 2006-06-23 16:08 Documents
drwxr-xr-x 1 tux users 70733 2006-06-21 09:35 public_html
-rw-r--r-- 1 tux users 47896 2006-06-21 09:46 tux.txt
tux@knox:~>
This output shows the following information about each object:
drwxr-xr-x 1 tux users 48 2006-06-23 16:08 bin
Type of object and access permissions. For further information, refer to Sec-
tion 6.3.1, “Permissions for User, Group and Others” (page 82).
Number of hard links to this le.
Owner of the le or directory. For further information, refer to Section 6.3.1,
“Permissions for User, Group and Others” (page 82).
Group assigned to the le or directory. For further information, refer to Sec-
tion 6.3.1, “Permissions for User, Group and Others” (page 82).
Shell Basics 87
97


Need help? Post your question in this forum.

Forumrules


Report abuse

Libble takes abuse of its services very seriously. We're committed to dealing with such abuse according to the laws in your country of residence. When you submit a report, we'll investigate it and take the appropriate action. We'll get back to you only if we require additional details or have more information to share.

Product:

For example, Anti-Semitic content, racist content, or material that could result in a violent physical act.

For example, a credit card number, a personal identification number, or an unlisted home address. Note that email addresses and full names are not considered private information.

Forumrules

To achieve meaningful questions, we apply the following rules:

Register

Register getting emails for Suse openSUSE 11.3 at:


You will receive an email to register for one or both of the options.


Get your user manual by e-mail

Enter your email address to receive the manual of Suse openSUSE 11.3 in the language / languages: English as an attachment in your email.

The manual is 7 mb in size.

 

You will receive the manual in your email within minutes. If you have not received an email, then probably have entered the wrong email address or your mailbox is too full. In addition, it may be that your ISP may have a maximum size for emails to receive.

The manual is sent by email. Check your email

If you have not received an email with the manual within fifteen minutes, it may be that you have a entered a wrong email address or that your ISP has set a maximum size to receive email that is smaller than the size of the manual.

The email address you have provided is not correct.

Please check the email address and correct it.

Your question is posted on this page

Would you like to receive an email when new answers and questions are posted? Please enter your email address.



Info