Add !! (bangbang) and !$ syntax
Created by: sajattack
I always forget sudo when running as user so it would be nice to have !!
so I could sudo !!
. In case anyone is unaware of what !! is it replays the last command in history. and !$ replays the args. Here's a quick example:
$ pkg install gcc
Error blah blah
$ sudo !!
sudo pkg install gcc
Success
$ ls /tmp
file.txt
file2.txt
$ rm -rf !$
rm -rf /tmp