summaryrefslogtreecommitdiff
path: root/src/user/app/shell/shell.h
blob: 5097e0002ef3ce768b99e1acb526442b921c5d9c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#pragma once
#include <stdbool.h>
#include <stddef.h>

#define eprintf(fmt, ...) fprintf(stderr, "sh: "fmt"\n" __VA_OPT__(,) __VA_ARGS__)

struct redir {
	const char *stdout;
	bool append;
};

int parse(char *s, char **argv, size_t argvlen, struct redir *redir);