diff options
author | Anton Kling <anton@kling.gg> | 2024-12-15 03:20:16 +0100 |
---|---|---|
committer | Anton Kling <anton@kling.gg> | 2024-12-15 03:20:16 +0100 |
commit | e28b7b21d308d7963aea6317a0a83e9de6ac0f45 (patch) | |
tree | c3b9f5c47a36cd777b83d145b24012637ed11a01 /userland/minibox/utilities/sh/lexer.c | |
parent | 19482e5ef5b6710b4b9a52edcb1bb39692336d7a (diff) |
sh: Add setting environment variables
Diffstat (limited to 'userland/minibox/utilities/sh/lexer.c')
-rw-r--r-- | userland/minibox/utilities/sh/lexer.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/userland/minibox/utilities/sh/lexer.c b/userland/minibox/utilities/sh/lexer.c index 09fc2ff..52126b4 100644 --- a/userland/minibox/utilities/sh/lexer.c +++ b/userland/minibox/utilities/sh/lexer.c @@ -24,7 +24,7 @@ int is_special_char(char c) { if (isalnum(c)) { return 0; } - return !(('>' != c && '|' != c && '&' != c)); + return !(('>' != c && '|' != c && '&' != c && '=' != c)); } int parse_chars(struct sv *code_ptr, struct TOKEN *cur) { @@ -54,6 +54,7 @@ int parse_operand(struct sv *code_ptr, struct TOKEN *cur) { TRY_PARSE_STRING(">", TOKEN_STREAM); TRY_PARSE_STRING("|", TOKEN_PIPE); TRY_PARSE_STRING("&", TOKEN_BACKGROUND); + TRY_PARSE_STRING("=", TOKEN_EQUAL); TRY_PARSE_STRING("\n", TOKEN_NEWLINE); // Failed to parse |