TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: What are your top 10 most used CLI tools?

13 pointsby brendanfalkover 4 years ago
The following should work in bash&#x2F;zsh<p>history | awk &#x27;{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] &quot; &quot; CMD[a]&#x2F;count*100 &quot;% &quot; a;}&#x27; | grep -v &quot;.&#x2F;&quot; | column -c3 -s &quot; &quot; -t | sort -nr | nl | head -n10<p>Mine are:<p><pre><code> 1 1922 19.1244% cd 2 1398 13.9104% git 3 1228 12.2189% fig 4 590 5.87065% open 5 497 4.94527% echo 6 309 3.07463% ls 7 275 2.73632% man 8 183 1.82090% heroku 9 175 1.74129% defaults 10 175 1.74129% curl </code></pre> Source: https:&#x2F;&#x2F;superuser.com&#x2F;questions&#x2F;250227&#x2F;how-do-i-see-what-my-most-used-linux-command-are

9 comments

diogenesjuniorover 4 years ago
<p><pre><code> 1 32 22.695% ls 2 23 16.3121% python3 3 17 12.0567% cd 4 12 8.51064% clear 5 9 6.38298% grep 6 8 5.67376% git 7 7 4.96454% pip3 8 6 4.25532% rm 9 5 3.5461% nano 10 4 2.83688% unlink </code></pre> I just got a new PC, so the numbers aren&#x27;t a good representation of how many times I use each command. I&#x27;d say that they&#x27;re in order though.
评论 #25319523 未加载
vram22over 4 years ago
#!&#x2F;bin&#x2F;bash --loose-syntax $ 10 Error: command not found.<p>&#x27;awk|bash|bc|c[au]t|ch{own,grp,mod}|c{ol,mp,omm}|{ls,ll,file,cp,mv,rm,ln}|{cd,popd,pushd,pwd,{mk,rm}dir}|{cron,at,crontab}|diff|d[uf]|{clear|echo|tput}|[ fe]grep|{e{d,macs},vi[ m]}|{[ c]fdisk,fsck,[ u]mount}|{find,locate,whatis, whereis,which}|{more,less,pg}|pr|lp{r,admin}|{tr|sed|sort}|su{ ,do}|{ping,traceroute,netstat,ssh,rcp}|xargs|yes&#x27;
kleer001over 4 years ago
<p><pre><code> 1 270 9.97783% ls 2 236 8.72136% &lt;custom crypto script&gt; 3 188 6.94752% cd 4 158 5.83888% clear 5 148 5.46933% emacs 6 120 4.43459% sudo 7 104 3.84331% &lt;custom script for writing&gt; 8 98 3.62158% ll 9 70 2.58684% j 10 64 2.36511% &lt;custom crypto script&gt; -</code></pre>
aprdmover 4 years ago
<p><pre><code> 1 1779 17.7918% ls 2 1732 17.3217% git 3 801 8.0108% cd 4 324 3.24032% docker 5 315 3.15032% vim 6 273 2.73027% rm 7 244 2.44024% curl 8 243 2.43024% ll 9 234 2.34023% cat 10 204 2.0402% docker-compose</code></pre>
sachinsmcover 4 years ago
<p><pre><code> 1 1188 13.5154% git 2 786 8.94198% ls 3 760 8.64619% cd 4 509 5.79067% npm 5 425 4.83504% ssh 6 410 4.66439% sudo 7 392 4.45961% node 8 257 2.92378% docker 9 249 2.83276% gst 10 182 2.07053% brew</code></pre>
frompdxover 4 years ago
<p><pre><code> 1 2466 23.2861% kubectl 2 1318 12.4457% vi 3 967 9.13126% cd 4 933 8.8102% ls 5 486 4.58924% docker 6 401 3.78659% terragrunt 7 334 3.15392% git 8 326 3.07838% curl 9 297 2.80453% janet 10 263 2.48347% cat</code></pre>
dinklebergover 4 years ago
<p><pre><code> 1 540 23.3766% ls 2 354 15.3247% cd 3 290 12.5541% kubectl 4 86 3.72294% git 5 63 2.72727% yarn 6 63 2.72727% mkdir 7 54 2.33766% ssh 8 52 2.25108% rm 9 47 2.03463% k9s 10 45 1.94805% scrapy</code></pre>
thijsvandienover 4 years ago
<p><pre><code> 1 139 27.8% rg 2 68 13.6% cd 3 36 7.2% brew 4 28 5.6% pip 5 27 5.4% pyenv 6 24 4.8% ls 7 17 3.4% git 8 16 3.2% cat 9 13 2.6% ssh 10 12 2.4% sudo</code></pre>
评论 #25329515 未加载
Breadmakerover 4 years ago
1 270 28,7234% sudo<p>2 72 7,65957% youtube-dl<p>3 57 6,06383% sync<p>4 31 3,29787% apt-get<p>5 30 3,19149% cd<p>6 27 2,87234% hdparm<p>7 26 2,76596% ls<p>8 23 2,44681% netstat<p>9 19 2,02128% cat<p>10 15 1,59574% df