]>
diplodocus.org Git - nmh/blob - h/msh.h
3 * msh.h -- definitions for msh
7 #define STDIO 0 /* regular stdoutput */
8 #define CRTIO 1 /* create re-direct */
9 #define APPIO 2 /* append re-direct */
10 #define PIPIO 3 /* pipe re-direct */
20 #define NULLCMD ((struct Cmd *) 0)
22 #define MHNCHK 0x0001 /* did nontext check */
23 #define MHNYES 0x0002 /* .. and known to be non-text */
26 * Determine the number of user defined sequences we
27 * can have. The first FFATTRSLOT sequence flags are for
28 * internal nmh message flags.
31 #define CUR (FFATTRSLOT + NUMATTRS - 1)
34 # define VIRTUAL SELECT_EMPTY
36 # define is_virtual(mp,msgnum) ((mp)->msgstats[msgnum] & VIRTUAL)
37 # define unset_virtual(mp,msgnum) ((mp)->msgstats[msgnum] &= ~VIRTUAL)
38 # define set_virtual(mp,msgnum) ((mp)->msgstats[msgnum] |= VIRTUAL)
49 #define m_bboard_id m_drop.d_id
50 #define m_top m_drop.d_size
51 #define m_start m_drop.d_start
52 #define m_stop m_drop.d_stop
57 extern char *fmsh
; /* folder instead of file */
58 extern int modified
; /* command modified folder */
59 extern struct msgs
*mp
; /* used a lot */
60 extern struct Msg
*Msgs
; /* Msgs[0] not used */
62 FILE *msh_ready (int, int);
67 extern int interactive
; /* running from a /dev/tty */
68 extern int redirected
; /* re-directing output */
69 extern FILE *sp
; /* original stdout */
70 extern char *cmd_name
; /* command being run */
71 extern char myfilter
[]; /* path to mhl.forward */
73 extern char *BBoard_ID
; /* BBoard-ID constant */
78 extern SIGNAL_HANDLER istat
; /* original SIGINT */
79 extern SIGNAL_HANDLER qstat
; /* original SIGQUIT */
80 extern int interrupted
; /* SIGINT detected */
81 extern int broken_pipe
; /* SIGPIPE detected */
82 extern int told_to_quit
; /* SIGQUIT detected */
93 void display_info (int);
95 void forkcmd (char **s
, char *);
96 void distcmd (char **);
97 void explcmd (char **);
98 int filehak (char **);
99 void filecmd (char **);
100 void foldcmd (char **);
101 void forwcmd (char **);
102 void helpcmd (char **);
103 void markcmd (char **);
104 void mhncmd (char **);
105 void showcmd (char **);
106 int pack (char *, int, int);
107 int packhak (char **);
108 void packcmd (char **);
109 void pickcmd (char **);
110 void replcmd (char **);
111 void rmmcmd (char **);
112 void scancmd (char **);
113 void sortcmd (char **);