elvish icon indicating copy to clipboard operation
elvish copied to clipboard

Support resetting all modules and bindings

Open xiaq opened this issue 3 years ago • 2 comments

When developing modules interactively, using exec is now the only way to get around the module cache. If there is a way to let the interpreter forget all modules and bindings, it could be used as a more lightweight "in-process" eval.

xiaq avatar Jun 22 '21 23:06 xiaq

Something similar to erlangs f() function would be nice http://erlang.org/doc/man/shell.html#shell-commands

shomodj avatar Jun 22 '21 23:06 shomodj

Would the hypothetical mechanism also reload rc.elv? Honestly, I don't see the point of the proposed feature since it is trivial to exec elvish. Except, of course, on Windows where exec isn't currently supported. But as I've commented elsewhere I think Elvish should use the MSYS2 Bash hack of translating exec cmd into cmd; exit on Windows.

krader1961 avatar Jun 28 '22 01:06 krader1961