Add project issues for lush (Lua + shell) features

Defines syntax decisions and implementation plan across 7 issues:
- backtick command execution returning {code, stdout, stderr}
- ${expr} interpolation in backticks
- $SIGIL env var read/write
- argv parsing, piping, and redirection (future)
This commit is contained in:
Cormac Shannon
2026-02-18 19:08:51 +00:00
parent 4cf498210e
commit db6f39a2a4
7 changed files with 249 additions and 0 deletions

26
issues/04-argv-parsing.md Normal file
View File

@@ -0,0 +1,26 @@
# 04 — Implement argv parsing (tokenize command strings)
**Status:** open
**Blocked by:** #01
**Blocks:** #06
Since we're not using a shell, we need our own command-line tokenizer to split a command string into `argv[]`.
## Must handle
- Simple whitespace splitting: `ls -l /tmp``["ls", "-l", "/tmp"]`
- Single-quoted strings: `echo 'hello world'``["echo", "hello world"]`
- Double-quoted strings with escapes: `echo "hello \"world\""`
- Backslash escaping outside quotes: `echo hello\ world`
- Mixed quoting: `echo "it's a test"`
## May handle (depending on #01 decisions)
- Variable/expression interpolation: `echo $HOME` or `echo ${dir}`
- Glob expansion: `ls *.lua` (could also defer to a later issue)
## Implementation
- Standalone C module, likely `lcmd_parse.c` or part of `lcmd.c`
- Returns a `char **argv` (NULL-terminated) + argc count
- Must handle memory allocation/cleanup