libdash icon indicating copy to clipboard operation
libdash copied to clipboard

Prompt callbacks

Open mgree opened this issue 5 years ago • 1 comments

libdash, by default, uses dash expansion prints the PS1 and PS2 in the dash prompt. This behavior is wrong (and possibly dangerous, depending on the use case).

We should make the prompt functions monkeypatchable, allowing users of the library to circumvent dash internals (beyond the alias table) entirely. In an ideal world, we could even compile just the few files necessary.

mgree avatar Dec 22 '20 21:12 mgree

With these callbacks, it should be possible to strip out much more of dash's code, working with just the bare C parser and AST. It's important to be careful about how dash's initialization happens, though.

mgree avatar Jul 11 '22 00:07 mgree