On Wed, Dec 1, 2010 at 1:34 PM, Chris Penn <cantorm...@gmail.com> wrote:
> Here is a fun list of bash commands. > http://houcemhachicha.blogspot.com/2010/07/my-top-ten-shellbash-tricks.html > > the one I did not think of when looking at the list: > > :~$ apt-get update > E: Could not open lock file /var/lib/apt/lists/lock - open (13: > Permission denied) > E: Unable to lock the list directory > :~$ sudo !! > Over the years this has been one of the most helpful tricks even though I didn't use it as often as others. Another one not mentioned is !*, which allows you to use the previous arguments with a new command not just the entire previous command like the double bang. $ cp apple orange $ ls -1 !* apple orange > > An oldie but goodie (do at your own risk): > :~$:(){ :|:& };: > Your top 10 commands(a bit to remember): > :~$ history |tr '\011' ' ' |tr -s " "| cut -d' ' -f3 |sort |uniq -c > |sort -nbr |head -n10 > > 168 sudo > 151 ssh > 133 nmap > 118 htop > 112 killall > 111 cd > 81 make > 29 find > 17 umount > 7 man > I'm not sure where this would actually be useful. I have always made my history unique so that I could continue to stuff it with new commands and not exceed the history limit as quickly. > > Chris... > -- > "As we open our newspapers or watch our television screens, we seem to > be continually assaulted by the fruits of Mankind's stupidity." > -Roger Penrose > _______________________________________________ > LinuxUsers mailing list > LinuxUsers@socallinux.org > http://socallinux.org/cgi-bin/mailman/listinfo/linuxusers >
_______________________________________________ LinuxUsers mailing list LinuxUsers@socallinux.org http://socallinux.org/cgi-bin/mailman/listinfo/linuxusers