Initial import of the CDE 2.1.30 sources from the Open Group.
[oweals/cde.git] / cde / programs / dtksh / aliases.c
1 /* $XConsortium: aliases.c /main/3 1995/11/01 15:50:11 rswiston $ */
2 /***************************************************************
3 *                                                              *
4 *                      AT&T - PROPRIETARY                      *
5 *                                                              *
6 *        THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF        *
7 *                    AT&T BELL LABORATORIES                    *
8 *         AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN         *
9 *            ACCORDANCE WITH APPLICABLE AGREEMENTS             *
10 *                                                              *
11 *          Copyright (c) 1993 AT&T Bell Laboratories           *
12 *              Unpublished & Not for Publication               *
13 *                     All Rights Reserved                      *
14 *                                                              *
15 *       The copyright notice above does not evidence any       *
16 *      actual or intended publication of such source code      *
17 *                                                              *
18 *               This software was created by the               *
19 *           Advanced Software Technology Department            *
20 *                    AT&T Bell Laboratories                    *
21 *                                                              *
22 *               For further information contact                *
23 *                    {ulysses,attmail}!dgk                     *
24 *                     dgk@ulysses.att.com                      *
25 *                   David Korn 908-582-7975                    *
26 *                                                              *
27 ***************************************************************/
28
29 /* : : generated by proto : : */
30
31
32 #if !defined(__PROTO__)
33 #if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus)
34 #if defined(__cplusplus)
35 #define __MANGLE__      "C"
36 #else
37 #define __MANGLE__
38 #endif
39 #define __STDARG__
40 #define __PROTO__(x)    x
41 #define __OTORP__(x)
42 #define __PARAM__(n,o)  n
43 #if !defined(__STDC__) && !defined(__cplusplus)
44 #if !defined(c_plusplus)
45 #define const
46 #endif
47 #define signed
48 #define void            int
49 #define volatile
50 #define __V_            char
51 #else
52 #define __V_            void
53 #endif
54 #else
55 #define __PROTO__(x)    ()
56 #define __OTORP__(x)    x
57 #define __PARAM__(n,o)  o
58 #define __MANGLE__
59 #define __V_            char
60 #define const
61 #define signed
62 #define void            int
63 #define volatile
64 #endif
65 #if defined(__cplusplus) || defined(c_plusplus)
66 #define __VARARG__      ...
67 #else
68 #define __VARARG__
69 #endif
70 #if defined(__STDARG__)
71 #define __VA_START__(p,a)       va_start(p,a)
72 #else
73 #define __VA_START__(p,a)       va_start(p)
74 #endif
75 #endif
76
77 #include        <ast.h>
78 #include        <signal.h>
79 #include        "FEATURE/options"
80 #include        "FEATURE/dynamic"
81 #include        "shtable.h"
82 #include        "name.h"
83
84 #include <X11/X.h>
85 #include <X11/Intrinsic.h>
86 #include <X11/IntrinsicP.h>
87 #define NO_AST
88 #include "dtksh.h"
89 #undef NO_AST
90 #include "dtextra.h"
91 #include "xmextra.h"
92 #include "msgs.h"
93
94 /*
95  * This is the table of built-in aliases.  These should be exported.
96  */
97
98 const struct shtable2 shtab_aliases[] =
99 {
100 #ifdef SHOPT_FS_3D
101         "2d",           NV_NOFREE|NV_EXPORT,    "set -f;_2d",
102 #endif /* SHOPT_FS_3D */
103         "autoload",     NV_NOFREE|NV_EXPORT,    "typeset -fu",
104         "command",      NV_NOFREE|NV_EXPORT,    "command ",
105         "fc",           NV_NOFREE|NV_EXPORT,    "hist",
106         "float",        NV_NOFREE|NV_EXPORT,    "typeset -E",
107         "functions",    NV_NOFREE|NV_EXPORT,    "typeset -f",
108         "hash",         NV_NOFREE|NV_EXPORT,    "alias -t --",
109         "history",      NV_NOFREE|NV_EXPORT,    "hist -l",
110         "integer",      NV_NOFREE|NV_EXPORT,    "typeset -i",
111         "nameref",      NV_NOFREE|NV_EXPORT,    "typeset -n",
112         "nohup",        NV_NOFREE|NV_EXPORT,    "nohup ",
113         "r",            NV_NOFREE|NV_EXPORT,    "hist -s",
114         "redirect",     NV_NOFREE|NV_EXPORT,    "command exec",
115         "times",        NV_NOFREE|NV_EXPORT,    "{ { time;} 2>&1;}",
116         "type",         NV_NOFREE|NV_EXPORT,    "whence -v",
117 #ifdef SIGTSTP
118         "stop",         NV_NOFREE|NV_EXPORT,    "kill -s STOP",
119         "suspend",      NV_NOFREE|NV_EXPORT,    "kill -s STOP $$",
120 #endif /*SIGTSTP */
121
122 DTK_EXTRA_ALIAS
123
124         "",             0,                      (char*)0
125 };