20 </style> |
20 </style> |
21 </head> |
21 </head> |
22 <body><a NAME="top" ID="top"></a> |
22 <body><a NAME="top" ID="top"></a> |
23 <h1>eric5.DebugClients.Python.getpass</h1> |
23 <h1>eric5.DebugClients.Python.getpass</h1> |
24 <p> |
24 <p> |
25 Module implementing utilities to get a password and/or the current user name. |
25 Module implementing utilities to get a password and/or the current user name. |
26 </p><p> |
26 </p><p> |
27 getpass(prompt) - prompt for a password, with echo turned off |
27 getpass(prompt) - prompt for a password, with echo turned off |
28 getuser() - get the user name from the environment or password database |
28 getuser() - get the user name from the environment or password database |
29 </p><p> |
29 </p><p> |
30 This module is a replacement for the one found in the Python distribution. It |
30 This module is a replacement for the one found in the Python distribution. It |
31 is to provide a debugger compatible variant of the a.m. functions. |
31 is to provide a debugger compatible variant of the a.m. functions. |
32 </p> |
32 </p> |
33 <h3>Global Attributes</h3> |
33 <h3>Global Attributes</h3> |
34 <table> |
34 <table> |
35 <tr><td>__all__</td></tr><tr><td>default_getpass</td></tr><tr><td>unix_getpass</td></tr><tr><td>win_getpass</td></tr> |
35 <tr><td>__all__</td></tr><tr><td>default_getpass</td></tr><tr><td>unix_getpass</td></tr><tr><td>win_getpass</td></tr> |
36 </table> |
36 </table> |
40 </table> |
40 </table> |
41 <h3>Functions</h3> |
41 <h3>Functions</h3> |
42 <table> |
42 <table> |
43 <tr> |
43 <tr> |
44 <td><a href="#getpass">getpass</a></td> |
44 <td><a href="#getpass">getpass</a></td> |
45 <td>Function to prompt for a password, with echo turned off.</td> |
45 <td>Function to prompt for a password, with echo turned off.</td> |
46 </tr><tr> |
46 </tr><tr> |
47 <td><a href="#getuser">getuser</a></td> |
47 <td><a href="#getuser">getuser</a></td> |
48 <td>Function to get the username from the environment or password database.</td> |
48 <td>Function to get the username from the environment or password database.</td> |
49 </tr> |
49 </tr> |
50 </table> |
50 </table> |
51 <hr /><hr /> |
51 <hr /><hr /> |
52 <a NAME="getpass" ID="getpass"></a> |
52 <a NAME="getpass" ID="getpass"></a> |
53 <h2>getpass</h2> |
53 <h2>getpass</h2> |
54 <b>getpass</b>(<i>prompt='Password: '</i>) |
54 <b>getpass</b>(<i>prompt='Password: '</i>) |
55 <p> |
55 <p> |
56 Function to prompt for a password, with echo turned off. |
56 Function to prompt for a password, with echo turned off. |
57 </p><dl> |
57 </p><dl> |
58 <dt><i>prompt</i></dt> |
58 <dt><i>prompt</i></dt> |
59 <dd> |
59 <dd> |
60 Prompt to be shown to the user (string) |
60 Prompt to be shown to the user (string) |
61 </dd> |
61 </dd> |
62 </dl><dl> |
62 </dl><dl> |
63 <dt>Returns:</dt> |
63 <dt>Returns:</dt> |
64 <dd> |
64 <dd> |
65 Password entered by the user (string) |
65 Password entered by the user (string) |
66 </dd> |
66 </dd> |
67 </dl> |
67 </dl> |
68 <div align="right"><a href="#top">Up</a></div> |
68 <div align="right"><a href="#top">Up</a></div> |
69 <hr /><hr /> |
69 <hr /><hr /> |
70 <a NAME="getuser" ID="getuser"></a> |
70 <a NAME="getuser" ID="getuser"></a> |
71 <h2>getuser</h2> |
71 <h2>getuser</h2> |
72 <b>getuser</b>(<i></i>) |
72 <b>getuser</b>(<i></i>) |
73 <p> |
73 <p> |
74 Function to get the username from the environment or password database. |
74 Function to get the username from the environment or password database. |
75 </p><p> |
75 </p><p> |
76 First try various environment variables, then the password |
76 First try various environment variables, then the password |
77 database. This works on Windows as long as USERNAME is set. |
77 database. This works on Windows as long as USERNAME is set. |
78 </p><dl> |
78 </p><dl> |
79 <dt>Returns:</dt> |
79 <dt>Returns:</dt> |
80 <dd> |
80 <dd> |
81 username (string) |
81 username (string) |
82 </dd> |
82 </dd> |
83 </dl> |
83 </dl> |
84 <div align="right"><a href="#top">Up</a></div> |
84 <div align="right"><a href="#top">Up</a></div> |
85 <hr /> |
85 <hr /> |
86 </body></html> |
86 </body></html> |