You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • You can force a newline that doesn't execute with Alt+Enter (27 + 10). If you obey really simple rules (run it through a lexer and then bracket count) you'll be able to ensure that every command you send to Espruino does finish.

    I don't think it does stop you implementing a nice CLI, as someone has already done with espruino-cli for node.

    Or your other option is to just do Serial1.setConsole() to get the JS console out of the way, and then you can implement whatever you like on USB by creating a handler with USB.onData(...).

    But I really don't think just implementing yet another CLI will help 99% of Espruino's users. It seems like several of the features you want could be implemented in Espruino itself, and then they'd be available to everyone regardless of their OS or what terminal they decided to use. There's already a command history by the way - or did you have something else in mind?

About

Avatar for Gordon @Gordon started