[riot-notifications] [RIOT-OS/RIOT] sys/shell: Exit the shell on ctrl-D (#10788)
notifications at github.com
Thu Sep 19 09:42:43 CEST 2019
> Ok, got it, but to quote yourself:
> > We just need to wrap existing consumers of the shell with a while loop to avoid functional changes in existing code which doesn't wish to have a shell capable of exiting.
> would mean to avoid functional changes we need to touch _every_ call of `shell_run`
I mean grep says it's not that many changes and all of them are simply adding a while(1) loop which should be trivial to review. We *do* need an exitable shell. End users can make an exitable shell non-exitable but they cannot make a non-exitable shell exitable.
> As a compromise: how about introducing `shell_run_once()` to the shell's with the current functionality of `shell_run()` (+ the one introduced in this PR) and moving `shell_run()` to a function that calls `shell_run_once()` in an infinite loop?
At a glance, I have no objection to this.
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the notifications