move all vt100 code to vt100 library
delay load event rare code
fix shell parse for %d>&%d not followed by whitespace
remove weird tty blink code and use vt100 codes
bump openos patch version
* Parse Lua REPL inputs with an implicit "return "
If an input does not start with a leading "=", this will parse the input
with "return " appended and, if that fails, will parse as a normal
statement.
This allows for normal expressions to be entered into the repl (such as
`2 + 2`) but does mean the parse errors for malformed inputs are
confusing. For instance, `3 + ` will error at '3' rather than '<eof>'.
* Do not insert into history if a duplicate
This mimics the behaviour of shells such as bash or zsh, where
whitespace-only lines are not entered into history, nor are ones equal
to the previous input. This makes history navigation slightly easier.
GPUs have neighbor visibility, and screens have network visibility. But in a robot the gpu and screen are sibling components, with edges to the machine, but without edges to each other. Thus during load they are not connected to each other (regardless of load order). Robots already have a provision for this issue for connecting screens to keyboards and keyboards to screens, but lacked a custom screen->gpu connection. This code change simply adds that search and connects all screens to all gpus.
closes#2302
/bin/less and /bin/more were able to lock up the system if they call string.gsub(string, function) on a very large string (~144k chars long).
The machine layer intercepts expensive strings calls by checking the length of the string, but it does not intercept gsub calls when the replace action is a function
The fix is to intercept all long string actions, not just non-function replacement gsub calls
Note that /bin/more is now more efficient and doesn't call string.gsub, but this is still the right fix to keep the sandbox from being able to lock up the system with string methods
* term.pull fix, the tty stream no longer needs a cursor object
* buffer reads now pass the original result and reason all the way back. this allows /bin/sh to distinguish ^c from ^d
* /bin/sh cleanup to not show prompt when there is no input tty
* /bin/cat chunk based [huge performance and memory savings, can handle enormous files now]
* /bin/sleep blinks now
* removed unnecessary methods from tty
* cursor blinking and scrolling terminal improvements
* fixed bad term call to tty write
/bin/sleep ^c was printing an error because it was returning the event data, which prompts was interpretting as error details [unexpected]
use a .prop file to have the robot component magic fs be ignored when running `install`
Changes
* thread: fix coma state issue where thread would not resume
* thread: add thread.current(), returns current thread [ the init thread is still technically not a thread ]
* tty: simplify the api with read, and separate all stream methods from the library
* sleep: /bin/sleep will now show blinking cursor and can be interrupted
* echo: use io.write instead of print. print loads slightly more resources
quiet mode in /bin/source was a mess -- making .shrc scripts not able to print. Also, a lot of the /bin/sh arg parsing code has traditionally been over complicated. cleaned that up as well thanks to old code that expected strings in the args having been removed some time ago