aboutsummaryrefslogtreecommitdiff
path: root/examples/dte/exec.h
diff options
context:
space:
mode:
Diffstat (limited to 'examples/dte/exec.h')
-rw-r--r--examples/dte/exec.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/examples/dte/exec.h b/examples/dte/exec.h
new file mode 100644
index 0000000..e40a11f
--- /dev/null
+++ b/examples/dte/exec.h
@@ -0,0 +1,37 @@
1#ifndef EXEC_H
2#define EXEC_H
3
4#include <stdbool.h>
5#include <sys/types.h>
6#include "editor.h"
7#include "spawn.h"
8#include "util/macros.h"
9
10typedef enum {
11 EXEC_INVALID = -1,
12 // Note: items below here need to be kept sorted
13 EXEC_BUFFER = 0,
14 EXEC_COMMAND,
15 EXEC_ERRMSG,
16 EXEC_EVAL,
17 EXEC_LINE,
18 EXEC_MSG,
19 EXEC_NULL,
20 EXEC_OPEN,
21 EXEC_SEARCH,
22 EXEC_TAG,
23 EXEC_TTY,
24 EXEC_WORD,
25} ExecAction;
26
27ssize_t handle_exec (
28 EditorState *e,
29 const char **argv,
30 ExecAction actions[3],
31 SpawnFlags spawn_flags,
32 bool strip_trailing_newline
33) NONNULL_ARGS;
34
35ExecAction lookup_exec_action(const char *name, int fd) NONNULL_ARGS;
36
37#endif