Closed khale closed 5 years ago
This pull request introduces 1 alert and fixes 2 when merging f252927fdce8c8da0e53ffd916190d200d05f84a into 3fb088b137a99437742da4953fd57f0a94097ac5 - view on LGTM.com
new alerts:
fixed alerts:
Comment posted by LGTM.com
This PR introduces some major changes to the shell. The most significant change (in f31ebb777e3ac227feb014d614940ec427db6670) makes it so that shell commands no longer need to be added to
shell.c
. Rather, the handler and the registration can all be in the subsystem of interest.Some other bells and whistles added in this PR include:
better help command with longest prefix matching. e.g. with the command:
$> pci dev bus slot fun
the help command understands$> help pci
and will print out the help string associated with that command.$> help p
will print the help string for every available command that matches the stringp
.new
history
command, also with LPM.$> history
<- prints out most recent history$> history 2
<- prints out the 2 most recent history items$> history pc
<- prints out all recent command invocations which match the stringpc
fish
-style autocompletion at the shell. As you type at the shell, the shell will predict commands based on your history. You can hit<TAB>
to accept the suggestion, followed by<ENTER>
to run it.