post-page

Most oft-used *NIX commands

8
responses
by
 
on
September 25th, 2006
in
Cool Scripts, LinkyLoo
heading
heading
heading
8
Responses

 

Comments

  1. Scott Burkett (2 comments.) says:

    If you run a lot of homemade scripts (or even aliases), then the list unfortunately doesn’t mean as much (assuming you are just interested in proper *NIX commands.)

    Here are mine, though:

    389 vi
    283 cd
    45 ls
    41 vrefs
    15 grep
    15 make
    14 sync
    13 uptime
    10 df
    9 less
    9 gen_banrules.sh
    9 banip
    8 finger
    7 tail
    7 man
    7 date
    6 rm
    6 pwd
    6 mysqldiff

    Also, a small change to the script (to sort reverse numeric):

    history|awk ‘{print $2}’|awk ‘BEGIN {FS=”|”} {print $1}’|sort|uniq -c|sort +0 -1 -rn | less

    Cheers.
    Scott

  2. Scott Burkett (2 comments.) says:

    If you run a lot of homemade scripts (or even aliases), then the list unfortunately doesn’t mean as much (assuming you are just interested in proper *NIX commands.)

    Here are mine, though:

    389 vi
    283 cd
    45 ls
    41 vrefs
    15 grep
    15 make
    14 sync
    13 uptime
    10 df
    9 less
    9 gen_banrules.sh
    9 banip
    8 finger
    7 tail
    7 man
    7 date
    6 rm
    6 pwd
    6 mysqldiff

    Also, a small change to the script (to sort reverse numeric):

    Change the last sort call to: sort +0 -1 -rn

    Cheers.
    Scott

  3. florian (2 comments.) says:

    cat .zsh/history | sed -r 's/([^[:space:]]+).*/\1/' | sort | uniq -c | sort -nr | less

    378 cd
    215 mplayer
    214 rm
    181 ls
    153 less
    145 sudo
    116 grep
    107 svn
    89 mv
    83 man
    55 unrar
    51 emacs
    48 mkdir
    36 mubase
    35 vlc
    33 cat
    27 tar
    22 dpkg
    20 unzip
    18 find
    16 apt-cache
    14 tail
    13 killall
    13 chmod
    12 echo
    12 aptitude
    10 zgrep
    10 perldoc
    10 cp

  4. florian (2 comments.) says:

    For zsh:

    cat .zhistory | sed -r 's/([^[:space:]]+).*/\1/' | sort | uniq -c | sort -nr | less

    378 cd
    214 rm
    181 ls
    153 less
    145 sudo
    116 grep
    107 svn
    89 mv
    83 man
    55 unrar
    51 emacs
    48 mkdir
    36 mubase
    35 vlc
    33 cat
    27 tar
    22 dpkg
    20 unzip
    18 find
    16 apt-cache
    14 tail
    13 killall
    13 chmod
    12 echo
    12 aptitude
    10 zgrep
    10 perldoc
    10 cp

  5. ketsugi (3 comments.) says:

    $ history|awk ‘{print $3.17 ($2)}’|awk ‘BEGIN {FS=”|”} {print $1.58 ($1)}’|sort|uniq -c|sort -r
    bash: syntax error near unexpected token `('

    Am I doing something wrong?

  6. Mark (118 comments.) says:

    Ketsugi,
    take the <code&gt out of the statement.

  7. Mike Little (1 comments.) says:

    On my laptop it’s:
    65 mv
    64 wget
    53 exit
    48 cd
    21 mkdir
    20 .
    19 ssh
    19 ls
    15 ~/wpdb
    14 sudo
    9 sync
    9 svn
    9 ping
    9 netstat
    9 mysqldump
    9 history
    8 ./refresh-wordpress
    7 ~/refresh-wordpress
    7 ps
    7 du

    On my server (as me) it’s:
    181 exit
    174 su
    84 cd
    71 mysql
    70 ls
    40 ps
    38 epsilon
    33 uptime
    30 pwd
    27 wget
    25 top
    15 .
    13 tar
    13 mv
    13 cp
    11 mysqladmin
    10 du
    9 lynx
    9 df
    8 users

    and on my server (as root) it’s:
    190 ls
    138 cd
    69 exit
    65 epsilon
    54 cp
    43 chown
    37 mv
    27 ps
    26 hostname
    26 .
    24 mysql
    23 chmod
    22 tar
    20 find
    19 pwd
    15 unzip
    15 du
    14 sudo
    14 rm
    13 chgrp



Trackbacks/Pingbacks

  1. […] found in this site history|awk ‘{print $2}’|awk ‘BEGIN {FS=”|”} {print $1}’|sort|uniq -c|sort -r […]

Obviously Powered by WordPress. © 2003-2013

page counter
css.php