Tải bản đầy đủ (.docx) (5 trang)

Getting Help

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (101.98 KB, 5 trang )

Getting Help 4
Objectives
Upon completion of this module, you should be able to:
• Display on-line manual pages, including different sections of the
manual
• Search the on-line manual pages by keyword, by section
 In order for the man -k command to work, the MANPATH variable must be set to:
/usr/local/man:/usr/share/man:/usr/openwin/share/man:/usr/dt/man and the catman
utility must be run by root. Depending on the processor, running this utility may take up to one
hour and should be done before teaching this section.
Discussion – How do you typically get information about how to complete
computer tasks? What types of information do you usually need?
Displaying Man Pages
The UNIX Programmer’s Manual (also called man pages) describes what you
need to know about the system’s on-line commands, system calls, file formats,
and system maintenance. The on-line man pages are part of the Linux
computing environment.
Using the manCommand
Use the man command to display on-line man pages for commands.
Command Format
man name
man -k keyword
man section section name
Using the man Command Without Options
$ man cd
Reformatting page. Wait... done
CD(1) Linux User’s Manual CD(1)
NAME
cd, chdir, pushd, popd, dirs - change working directory
SYNOPSIS
/usr/bin/cd [ directory ]


sh
cd [ argument ]
chdir [ argument ]
DESCRIPTION
/usr/bin/cd
The cd utility will change the working directory of the
current shell execution environment. When invoked with
no operands, and the HOME environment variable is set
to a non-empty value, the directory named in the HOME
environment variable will become the new working
directory.
<Output Omitted>
OPERANDS
The following operands are supported:
directory An absolute or relative pathname of the
directory that becomes the new working directory. The
interpretation of a relative pathname by cd depends on
the CDPATH environment variable.
SEE ALSO
csh(1), ksh(1), pwd(1), sh(1), chdir(2), attributes(5),
environ(5)
(END)
Scrolling in Man Pages
Use the following keys to control the scrolling capabilities while using the
man command:
Spacebar Scroll through a manual page one screen at a time
Return Scroll through a manual page one line at a time
b Move back one screen
f Move forward one screen
q Quit the man command

/ string Search forward for information
n Find the next occurrence of string
h Give a description of all scrolling capabilities
Searching Man Pages by Section
There are multiple sections in the man pages. The SEE ALSO part at the
bottom of a man page lists alternate references that pertain to the topic
addressed. When these references are followed by a number other than
1 in parentheses, it indicates a section of the man pages which can be
accessed using the -S option with the man command.
For example, executing $ man passwd will display information on the
passwd command and give instructions on how to change a password.
The SEE ALSO section of this man page reads in part as follows:
SEE ALSO
finger(1), login(1), nispasswd(1), crypt(3C),
passwd(4)
Executing $ man -S 4 passwd will display information on the
/etc/passwd file and $ man –S 3C crypt will display information on
password encryption.
Searching Man Pages by Keyword
If you are not sure of the command name, use the -k option to specify a
keyword as a subject.
$ man -k insert
insque (3) – insert/remove an item from queue
remque [insque](3) - insert/remove an item from queue
wrjpgcom (1) – insert text coments into JPG file
Note – Using $ whatis command will display the header line from the
manual section. The man page itself can then be displayed with by using
the man command.
Exercise: Getting Help
Exercise objective – In this lab you will practice using the help functions

available with CDE and the command-line man pages.
Tasks
Complete the following steps:
1. Display the on-line manual (man) page for the ls command.
2. Display the on-line manual pages for the passwd command and the passwd
file.
3. Find the on-line manual page that describes how to clear the terminal screen
(use the keyword “clear”).
Workshop Labs
Use what you have learned so far in this course to work through the following:
1. Using the Calendar Manager, add an appointment for lunchtime on every
Wednesday for the next month. Have the system send you an email message
30 minutes before the appointment and place a reminder on your desktop 10
minutes before the appointment. Use any version of help you need to perform
this task.
2. What meaning would an ampersand “&” in the gcos field of a password file
entry carry for the system?
Exercise Summary
Discussion – Take a few minutes to discuss what experiences, issues, or
discoveries you had during the lab exercises.
 Manage the discussion here based on the time allowed for this module, which was given in
the “About This Course” module. If you find you do not have time to spend on
discussion, then just highlight the key concepts students should have learned from the lab
exercise.
• Experiences
 Ask students what their overall experiences with this exercise have been. You might want
to go over any trouble spots or especially confusing areas at this time.
• Interpretations
 Ask students to interpret what they observed during any aspects of this exercise.
• Conclusions

 Have students articulate any conclusions they reached as a result of this exercise
experience.
• Applications
 Explore with students how they might apply what they learned in this exercise to
situations at their workplace.
Exercise Solutions
1. Display the on-line manual (man) page for the ls command.
man ls
2. Display the on-line manual pages for the passwd command and the passwd
file.
man passwd
man -s 4 passwd
3. Find the on-line manual page that describes how to clear the terminal screen
(use the keyword “clear”).
man -k clear
Check Your Progress
Before continuing on to the next module, check that you are able to
accomplish or answer the following:
 Describe how to obtain help from the Front Panel
 Describe how to obtain application-specific help
 Invoke the Help Viewer from the Front Panel
 Invoke help from an application window
 Display on-line manual pages, including different sections of the manual
 Search the on-line manual pages by keyword
Think Beyond
Which type of help would you be most likely to use? Would this change depend
on what you needed help on?

Tài liệu bạn tìm kiếm đã sẵn sàng tải về

Tải bản đầy đủ ngay
×