Implemented unix-style reverse history search

Added cli history search, similar to linux. Usage:

`ctrl+r` `part-of-command`

`enter` to run, `leftarrow` or `rightarrow` to edit the command. Unlike the standard linux reverse-i-search, this one does not show the last matching command if the pattern is not found.