Created
June 3, 2011 13:46
-
-
Save randika/1006368 to your computer and use it in GitHub Desktop.
How To Search Shell Command History
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Search all history | |
randika@randika-XPS-M1330:~$ history | |
1 sudo apt-get install aptitude | |
2 sudo aptitude update | |
3 sudo aptitude install build-essential curl git-core | |
........ | |
........ | |
29 chmod 400 xxxxx.pem | |
30 ssh -i xxxxx.pem [email protected] | |
# Search particular command, enter: | |
randika@randika-XPS-M1330:~$ history | grep -i 'ssh' | |
ssh -i xxxxx.pem [email protected] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment