On Tue, Sep 3, 2013 at 12:36 PM, Sergei Gavrikov
<[email protected]>wrote:

> history | gawk \
>   '{if($2=="f"||$2=="fossil")s[$3]++}END{for(i in s)print s[i],i}'|sort -Vr
>

Nice use of awk! That one is going in my notes. -V doesn't work on the sort
available for me but -nr works nice. I keep most of my command line history
in an sqlite3 db. Unfortunately only unique commands are stored but the
stats from that are sort of interesting:

hs % | gawk '{if($1=="f"||$1=="fossil"||$1=="fsl")s[$2]++}END{for(i in
s)print s[i],i}' | sort -nr
788 ci
200 add
125 commit
119 set
114 merge
98 rm
98 diff
91 help
91 co
83 repo
67 open
58 clone
51 user
46 update
46 sync
37 extras
35 branch
32 mv
30 gdiff
29 revert
26 tag
21 timeline
20 status
19 ui
19 info
14 remote-url
13 leaves
11 stash
11 checkout
10 settings
10 ls
10 finfo
8 new
8 bisect
7 rebuild
7 pull
6 ticket
6 serve
6 init
5 setting
4 up
4 test-move-repository
4 server
4 json
4 getrepo
4 createrepo
4 cat
4 all
3 history
3 annotate
2 wiki
2 version
2 unset
2 undo
2 test-canonical-name
2 shash
2 sett
2 reset
2 repol
2 log
2 changes
1 vlist
1 update;make
1 trunk
1 tkdiff
1 timeoline
1 time
1 testconfig
1 tech
1 submit
1 sqlite3


-- 
Matt
-=-
90% of the nations wealth is held by 2% of the people. Bummer to be in the
majority...
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to