annotate Doc/lib/libgetpass.tex @ 21467:4e35fa5d5708 legacy-trunk

Add documentation for the help() built-in; contributed by Ka-Ping Yee. This is part of SF patch #494622.
author Fred Drake <fdrake@acm.org>
date Tue, 18 Dec 2001 16:31:08 +0000
parents bc02c3b09626
children fe3b93c22481
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
1 \section{\module{getpass}
10387
9c5d9bdf7e42 Added availabililty annotations to respond to concerns of /F.
Fred Drake <fdrake@acm.org>
parents: 9715
diff changeset
2 --- Portable password input}
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
3
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
4 \declaremodule{standard}{getpass}
10387
9c5d9bdf7e42 Added availabililty annotations to respond to concerns of /F.
Fred Drake <fdrake@acm.org>
parents: 9715
diff changeset
5 \modulesynopsis{Portable reading of passwords and retrieval of the userid.}
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
6 \moduleauthor{Piers Lauder}{piers@cs.su.oz.au}
10387
9c5d9bdf7e42 Added availabililty annotations to respond to concerns of /F.
Fred Drake <fdrake@acm.org>
parents: 9715
diff changeset
7 % Windows (& Mac?) support by Guido van Rossum.
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
8 \sectionauthor{Fred L. Drake, Jr.}{fdrake@acm.org}
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
9
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
10
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
11 The \module{getpass} module provides two functions:
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
12
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
13
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
14 \begin{funcdesc}{getpass}{\optional{prompt}}
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
15 Prompt the user for a password without echoing. The user is
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
16 prompted using the string \var{prompt}, which defaults to
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
17 \code{'Password: '}.
21062
bc02c3b09626 Clean up some markup cruft. A number of the macros that take no
Fred Drake <fdrake@acm.org>
parents: 10703
diff changeset
18 Availability: Macintosh, \UNIX, Windows.
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
19 \end{funcdesc}
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
20
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
21
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
22 \begin{funcdesc}{getuser}{}
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
23 Return the ``login name'' of the user.
21062
bc02c3b09626 Clean up some markup cruft. A number of the macros that take no
Fred Drake <fdrake@acm.org>
parents: 10703
diff changeset
24 Availability: \UNIX, Windows.
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
25
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
26 This function checks the environment variables \envvar{LOGNAME},
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
27 \envvar{USER}, \envvar{LNAME} and \envvar{USERNAME}, in order, and
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
28 returns the value of the first one which is set to a non-empty
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
29 string. If none are set, the login name from the password database
10703
e4e800a78d8d Make internal module references hyperlinks wherever it makes sense.
Fred Drake <fdrake@acm.org>
parents: 10387
diff changeset
30 is returned on systems which support the \refmodule{pwd} module,
9715
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
31 otherwise, an exception is raised.
d1db7f6ab753 Basic documentation for the getpass module.
Fred Drake <fdrake@acm.org>
parents:
diff changeset
32 \end{funcdesc}