adaszko / complgen

Declarative bash/fish/zsh completions without writing shell scripts
Apache License 2.0
221 stars 7 forks source link

Parsing of statement-level shell code in grammars (`@{bash,fish,zsh} {{{ ... }}}`) #6

Closed adaszko closed 1 year ago

adaszko commented 1 year ago

The parser is to be extended to support a new Statement enum variant: Statement::ShellCode { code: ustr; }. Those blocks of code will be copied verbatim into the output shell scripts so that complgen supports executing pieces of shell scripts larger than what fits inside inline ones (e.g. { ls }), but this issue is only about parsing. It’s going to need several tests to check the parsing works as intended.

adaszko commented 1 year ago

That’s going to be too unwieldy to use. Need to think of a different solution.