xref: /original-bsd/usr.bin/tip/cmdtab.c (revision c3e32dec)
1 /*
2  * Copyright (c) 1983, 1993
3  *	The Regents of the University of California.  All rights reserved.
4  *
5  * %sccs.include.redist.c%
6  */
7 
8 #ifndef lint
9 static char sccsid[] = "@(#)cmdtab.c	8.1 (Berkeley) 06/06/93";
10 #endif /* not lint */
11 
12 #include "tip.h"
13 
14 extern	int shell(), getfl(), sendfile(), chdirectory();
15 extern	int finish(), help(), pipefile(), pipeout(), consh(), variable();
16 extern	int cu_take(), cu_put(), dollar(), genbrk(), suspend();
17 
18 esctable_t etable[] = {
19 	{ '!',	NORM,	"shell",			 shell },
20 	{ '<',	NORM,	"receive file from remote host", getfl },
21 	{ '>',	NORM,	"send file to remote host",	 sendfile },
22 	{ 't',	NORM,	"take file from remote UNIX",	 cu_take },
23 	{ 'p',	NORM,	"put file to remote UNIX",	 cu_put },
24 	{ '|',	NORM,	"pipe remote file",		 pipefile },
25 	{ '$',	NORM,	"pipe local command to remote host", pipeout },
26 #ifdef CONNECT
27 	{ 'C',  NORM,	"connect program to remote host",consh },
28 #endif
29 	{ 'c',	NORM,	"change directory",		 chdirectory },
30 	{ '.',	NORM,	"exit from tip",		 finish },
31 	{CTRL('d'),NORM,"exit from tip",		 finish },
32 	{CTRL('y'),NORM,"suspend tip (local+remote)",	 suspend },
33 	{CTRL('z'),NORM,"suspend tip (local only)",	 suspend },
34 	{ 's',	NORM,	"set variable",			 variable },
35 	{ '?',	NORM,	"get this summary",		 help },
36 	{ '#',	NORM,	"send break",			 genbrk },
37 	{ 0, 0, 0 }
38 };
39