You can first set the bash mode to vi. This will enable some vim like features to bash. So, add this to .bashrc :
set -o vi
Once, you have done that then its time to get more out of the vi mode. First, check some things and set some interesting stuff.
#Display all the bindings :
#Copy the current bindings and use it in inputrc:
bind -p |grep -v self-insert>~/.inputrc
In the inputrc, so generated, all the functions and macros not bound are commented with “#” and you can set them to your choice as in other examples.
And here is a link that can get you started.
If you want to force a fsck re-check on reboot, then just
Here is something that I found on the commandlinefu
cp /work/host/phone/ui/main.cpp !#$:s/host/target
Ah well…its very interesting and very useful.
!# – means the current command (similar to !! being the last command)
$ – represents the last parameter
:s – is used for substitution.