manipulating commands using keyboard maps

The inputrc file handles keyboard mapping for specific situations. This file is the startup file used by Readline — the input-related library — used by Bash and most other shells.

suppose you want to run a command witha specific keystroke eg : ctl+e to give the out put ls -la
 
you will need to append the following to the /etc/inputrc file
 
Control-e: "ls -la\n"
 
save the file
 
bind -f /etc/inputrc ------------> to the the changes may be relflected

now try to do a control +e and theout put on the screen will be a ls -la
 
--

No comments:

Other Articles

Enter your email address: