[riot-notifications] [RIOT-OS/RIOT] sys/shell: Exit the shell on ctrl-D (#10788)

Thomas Stilwell 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`

Yes, correct.

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...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190919/331352c7/attachment.htm>

More information about the notifications mailing list