Keyboard shortcut for last entered param in command line ?
I watched a linux tut video and noticed some cool trick. Can you explain how he managed to insert string "/sbin/mkfs.ext2" at 0:30 ? He hadn't selected it before. Is it some sort of keyboard shortcut for last entered param ?
http://www.youtube.com/watch?v=ZIQCd1RvbGk |
I don't speak that language. Maybe Ctrl+P for last entered.
|
You can print last argument of previously run command using ALT + . (ALT key plus dot) keyboard combination.
Code:
bash$ ls -ld /home/jack/test Code:
bash$ cd /home/jack/test |
Ctrl+Alt+y would also do it. Reference here.
|
Simply you can use up arrow key to get last command.
And using exclamatory(!) symbol also you can excecute the commands of previous command(s). For example I have ran 3 commands Code:
vi /etc/samba/smb.conf -->1st Code:
!v Code:
#history Code:
!2030 |
Thanks! You are so incredibly helpful )
|
Quote:
|
All times are GMT -5. The time now is 07:41 AM. |