| 1 |
.\" ''' $Id: cu.1,v 1.10 2002/03/05 22:13:33 ian Rel $ |
| 2 |
.TH cu 1 "Taylor UUCP 1.07" |
| 3 |
.SH NAME |
| 4 |
cu \- Call up another system |
| 5 |
.SH SYNOPSIS |
| 6 |
.B cu |
| 7 |
[ options ] [ system | phone | "dir" ] |
| 8 |
.SH DESCRIPTION |
| 9 |
The |
| 10 |
.I cu |
| 11 |
command is used to call up another system and act as a dial in |
| 12 |
terminal. It can also do simple file transfers with no error |
| 13 |
checking. |
| 14 |
|
| 15 |
.I cu |
| 16 |
takes a single argument, besides the options. If the argument is the |
| 17 |
string "dir" cu will make a direct connection to the port. This may |
| 18 |
only be used by users with write access to the port, as it permits |
| 19 |
reprogramming the modem. |
| 20 |
|
| 21 |
Otherwise, if the argument begins with a digit, it is taken to be a |
| 22 |
phone number to call. Otherwise, it is taken to be the name of a |
| 23 |
system to call. The |
| 24 |
.B \-z |
| 25 |
or |
| 26 |
.B \-\-system |
| 27 |
option may be used to name a system beginning with a digit, and the |
| 28 |
.B \-c |
| 29 |
or |
| 30 |
.B \-\-phone |
| 31 |
option may be used to name a phone number that does not begin with a |
| 32 |
digit. |
| 33 |
|
| 34 |
.I cu |
| 35 |
locates a port to use in the UUCP configuration files. If a simple |
| 36 |
system name is given, it will select a port appropriate for that |
| 37 |
system. The |
| 38 |
.B \-p, \-\-port, \-l, \-\-line, \-s |
| 39 |
and |
| 40 |
.B \-\-speed |
| 41 |
options may be used to control the port selection. |
| 42 |
|
| 43 |
When a connection is made to the remote system, |
| 44 |
.I cu |
| 45 |
forks into two processes. One reads from the port and writes to the |
| 46 |
terminal, while the other reads from the terminal and writes to the |
| 47 |
port. |
| 48 |
|
| 49 |
.I cu |
| 50 |
provides several commands that may be used during the conversation. |
| 51 |
The commands all begin with an escape character, initially |
| 52 |
.B ~ |
| 53 |
(tilde). The escape character is only recognized at the beginning of |
| 54 |
a line. To send an escape character to the remote system at the start |
| 55 |
of a line, it must be entered twice. All commands are either a single |
| 56 |
character or a word beginning with |
| 57 |
.B % |
| 58 |
(percent sign). |
| 59 |
|
| 60 |
.I cu |
| 61 |
recognizes the following commands: |
| 62 |
|
| 63 |
.TP 5 |
| 64 |
.B ~. |
| 65 |
Terminate the conversation. |
| 66 |
.TP 5 |
| 67 |
.B ~! command |
| 68 |
Run command in a shell. If command is empty, starts up a shell. |
| 69 |
.TP 5 |
| 70 |
.B ~$ command |
| 71 |
Run command, sending the standard output to the remote system. |
| 72 |
.TP 5 |
| 73 |
.B ~| command |
| 74 |
Run command, taking the standard input from the remote system. |
| 75 |
.TP 5 |
| 76 |
.B ~+ command |
| 77 |
Run command, taking the standard input from the remote system and |
| 78 |
sending the standard output to the remote system. |
| 79 |
.TP 5 |
| 80 |
.B ~#, ~%break |
| 81 |
Send a break signal, if possible. |
| 82 |
.TP 5 |
| 83 |
.B ~c directory, ~%cd directory |
| 84 |
Change the local directory. |
| 85 |
.TP 5 |
| 86 |
.B ~> file |
| 87 |
Send a file to the remote system. This just dumps the file over the |
| 88 |
communication line. It is assumed that the remote system is expecting |
| 89 |
it. |
| 90 |
.TP 5 |
| 91 |
.B ~< |
| 92 |
Receive a file from the remote system. This prompts for the local |
| 93 |
file name and for the remote command to execute to begin the file |
| 94 |
transfer. It continues accepting data until the contents of the |
| 95 |
.B eofread |
| 96 |
variable are seen. |
| 97 |
.TP 5 |
| 98 |
.B ~p from to, ~%put from to |
| 99 |
Send a file to a remote Unix system. This runs the appropriate |
| 100 |
commands on the remote system. |
| 101 |
.TP 5 |
| 102 |
.B ~t from to, ~%take from to |
| 103 |
Retrieve a file from a remote Unix system. This runs the appropriate |
| 104 |
commands on the remote system. |
| 105 |
.TP 5 |
| 106 |
.B ~s variable value |
| 107 |
Set a |
| 108 |
.I cu |
| 109 |
variable to the given value. If value is not given, the variable is |
| 110 |
set to |
| 111 |
.B true. |
| 112 |
.TP 5 |
| 113 |
.B ~! variable |
| 114 |
Set a |
| 115 |
.I cu |
| 116 |
variable to |
| 117 |
.B false. |
| 118 |
.TP 5 |
| 119 |
.B ~z |
| 120 |
Suspend the cu session. This is only supported on some systems. On |
| 121 |
systems for which ^Z may be used to suspend a job, |
| 122 |
.B ~^Z |
| 123 |
will also suspend the session. |
| 124 |
.TP 5 |
| 125 |
.B ~%nostop |
| 126 |
Turn off XON/XOFF handling. |
| 127 |
.TP 5 |
| 128 |
.B ~%stop |
| 129 |
Turn on XON/XOFF handling. |
| 130 |
.TP 5 |
| 131 |
.B ~v |
| 132 |
List all the variables and their values. |
| 133 |
.TP 5 |
| 134 |
.B ~? |
| 135 |
List all commands. |
| 136 |
|
| 137 |
.I cu |
| 138 |
also supports several variables. They may be listed with the |
| 139 |
.B ~v |
| 140 |
command, and set with the |
| 141 |
.B ~s |
| 142 |
or |
| 143 |
.B ~! |
| 144 |
commands. |
| 145 |
|
| 146 |
.TP 5 |
| 147 |
.B escape |
| 148 |
The escape character. Initially |
| 149 |
.B ~ |
| 150 |
(tilde). |
| 151 |
.TP 5 |
| 152 |
.B delay |
| 153 |
If this variable is true, |
| 154 |
.I cu |
| 155 |
will delay for a second after recognizing the escape character before |
| 156 |
printing the name of the local system. The default is true. |
| 157 |
.TP 5 |
| 158 |
.B eol |
| 159 |
The list of characters which are considered to finish a line. The |
| 160 |
escape character is only recognized after one of these is seen. The |
| 161 |
default is carriage return, ^U, ^C, ^O, ^D, ^S, ^Q, ^R. |
| 162 |
.TP 5 |
| 163 |
.B binary |
| 164 |
Whether to transfer binary data when sending a file. If this is |
| 165 |
false, then newlines in the file being sent are converted to carriage |
| 166 |
returns. The default is false. |
| 167 |
.TP 5 |
| 168 |
.B binary-prefix |
| 169 |
A string used before sending a binary character in a file transfer, if |
| 170 |
the |
| 171 |
.B binary |
| 172 |
variable is true. The default is ^V. |
| 173 |
.TP 5 |
| 174 |
.B echo-check |
| 175 |
Whether to check file transfers by examining what the remote system |
| 176 |
echoes back. This probably doesn't work very well. The default is |
| 177 |
false. |
| 178 |
.TP 5 |
| 179 |
.B echonl |
| 180 |
The character to look for after sending each line in a file. The |
| 181 |
default is carriage return. |
| 182 |
.TP 5 |
| 183 |
.B timeout |
| 184 |
The timeout to use, in seconds, when looking for a character, either |
| 185 |
when doing echo checking or when looking for the |
| 186 |
.B echonl |
| 187 |
character. The default is 30. |
| 188 |
.TP 5 |
| 189 |
.B kill |
| 190 |
The character to use delete a line if the echo check fails. The |
| 191 |
default is ^U. |
| 192 |
.TP 5 |
| 193 |
.B resend |
| 194 |
The number of times to resend a line if the echo check continues to |
| 195 |
fail. The default is 10. |
| 196 |
.TP 5 |
| 197 |
.B eofwrite |
| 198 |
The string to write after sending a file with the |
| 199 |
.B ~> |
| 200 |
command. The default is ^D. |
| 201 |
.TP 5 |
| 202 |
.B eofread |
| 203 |
The string to look for when receiving a file with the |
| 204 |
.B ~< |
| 205 |
command. The default is $, which is intended to be a typical shell |
| 206 |
prompt. |
| 207 |
.TP 5 |
| 208 |
.B verbose |
| 209 |
Whether to print accumulated information during a file transfer. The |
| 210 |
default is true. |
| 211 |
.SH OPTIONS |
| 212 |
The following options may be given to |
| 213 |
.I cu. |
| 214 |
.TP 5 |
| 215 |
.B \-e, \-\-parity=even |
| 216 |
Use even parity. |
| 217 |
.TP 5 |
| 218 |
.B \-o, \-\-parity=odd |
| 219 |
Use odd parity. |
| 220 |
.TP 5 |
| 221 |
.B \-\-parity=none |
| 222 |
Use no parity. No parity is also used if both |
| 223 |
.B \-e |
| 224 |
and |
| 225 |
.B \-o |
| 226 |
are given. |
| 227 |
.TP 5 |
| 228 |
.B \-h, \-\-halfduplex |
| 229 |
Echo characters locally (half-duplex mode). |
| 230 |
.TP 5 |
| 231 |
.B \-\-nostop |
| 232 |
Turn off XON/XOFF handling (it is on by default). |
| 233 |
.TP 5 |
| 234 |
.B \-f, \-\-nortscts |
| 235 |
Do not use hardware flow control. |
| 236 |
.TP 5 |
| 237 |
.B \-E char, \-\-escape char |
| 238 |
Set the escape character. Initially |
| 239 |
.B ~ |
| 240 |
(tilde). To eliminate the escape character, use |
| 241 |
.B -E ''. |
| 242 |
.TP 5 |
| 243 |
.B \-z system, \-\-system system |
| 244 |
The system to call. |
| 245 |
.TP 5 |
| 246 |
.B \-c phone-number, \-\-phone phone-number |
| 247 |
The phone number to call. |
| 248 |
.TP 5 |
| 249 |
.B \-p port, \-\-port port |
| 250 |
Name the port to use. |
| 251 |
.TP 5 |
| 252 |
.B \-a port |
| 253 |
Equivalent to |
| 254 |
.B \-\-port port. |
| 255 |
.TP 5 |
| 256 |
.B \-l line, \-\-line line |
| 257 |
Name the line to use by giving a device name. This may be used to |
| 258 |
dial out on ports that are not listed in the UUCP configuration files. |
| 259 |
Write access to the device is required. |
| 260 |
.TP 5 |
| 261 |
.B \-s speed, \-\-speed speed |
| 262 |
The speed (baud rate) to use. |
| 263 |
.TP 5 |
| 264 |
.B \-# |
| 265 |
Where # is a number, equivalent to |
| 266 |
.B \-\-speed #. |
| 267 |
.TP 5 |
| 268 |
.B \-n, \-\-prompt |
| 269 |
Prompt for the phone number to use. |
| 270 |
.TP 5 |
| 271 |
.B \-d |
| 272 |
Enter debugging mode. Equivalent to |
| 273 |
.B \-\-debug all. |
| 274 |
.TP 5 |
| 275 |
.B \-x type, \-\-debug type |
| 276 |
Turn on particular debugging types. The following types are |
| 277 |
recognized: abnormal, chat, handshake, uucp-proto, proto, port, |
| 278 |
config, spooldir, execute, incoming, outgoing. Only abnormal, chat, |
| 279 |
handshake, port, config, incoming and outgoing are meaningful for |
| 280 |
.I cu. |
| 281 |
|
| 282 |
Multiple types may be given, separated by commas, and the |
| 283 |
.B \-\-debug |
| 284 |
option may appear multiple times. A number may also be given, which |
| 285 |
will turn on that many types from the foregoing list; for example, |
| 286 |
.B \-\-debug 2 |
| 287 |
is equivalent to |
| 288 |
.B \-\-debug abnormal,chat. |
| 289 |
.B \-\-debug all |
| 290 |
may be used to turn on all debugging options. |
| 291 |
.TP 5 |
| 292 |
.B \-I file, \-\-config file |
| 293 |
Set configuration file to use. This option may not be available, |
| 294 |
depending upon how |
| 295 |
.I cu |
| 296 |
was compiled. |
| 297 |
.TP 5 |
| 298 |
.B \-v, \-\-version |
| 299 |
Report version information and exit. |
| 300 |
.TP 5 |
| 301 |
.B \-\-help |
| 302 |
Print a help message and exit. |
| 303 |
.SH BUGS |
| 304 |
This program does not work very well. |
| 305 |
.SH AUTHOR |
| 306 |
Ian Lance Taylor |
| 307 |
<[email protected]> |