
Ask HN: What are your favorite terminal programs? - orcs
The title and why?<p>Recently discovered CMus and am a big fan of Pandoc and youtube-dl.<p>This has me wondering what else I&#x27;m missing out on.
======
Dowwie
Written in Rust:

    
    
        - fd: A simple, fast and user-friendly alternative to 'find'
        https://github.com/sharkdp/fd
    
        - ripgrep: ripgrep recursively searches directories for a regex pattern
        https://github.com/BurntSushi/ripgrep
    
        - exa: Replacement for 'ls' written in Rust
        https://github.com/ogham/exa
    
        - bat: A 'cat' replacement.  I recommend following the customizations.
        https://github.com/sharkdp/bat
    
    

Written in Python:

    
    
        - asciinema: Terminal session recorder
        https://github.com/asciinema/asciinema
    
        - httpie: Modern command line HTTP client
        https://github.com/jakubroztocil/httpie
    
        - visidata: A terminal spreadsheet multitool for discovering and arranging data
        https://github.com/saulpw/visidata
    
        - youtube-dl: Command-line program to download videos from YouTube.com and other video sites
        https://github.com/rg3/youtube-dl
    
        - pgcli:  Postgres cli with autocomplete and syntax highlighting
        https://github.com/dbcli/pgcli
    
    

Written in C

    
    
        - jq: Command-line JSON processor
        https://github.com/stedolan/jq
    
        - tmux:  a terminal multiplexer
        https://github.com/tmux/tmux
    
        - pspg:  postgres pager (you can combine it with pgcli)
        https://github.com/okbob/pspg

~~~
jameskegel
I wish HN handled long horizontal scrolling lines on mobile better. It’s
aggravating that we are a site full of programmers and we can’t get the basics
of usability in 2018.

~~~
JoshCole
One thing that I think most people don't consider often is that making things
more usable isn't always good. Medium and message are interlinked. If everyone
in the world switched to mobile, it would change the content of the articles
we read and it would change the discussion of those articles. When you make
something more usable on a different platform, you're encouraging the biases
that the platform compels. In the case of mobile this means encouraging
shallower content and briefer discussions, among other things.

~~~
hyperpallium
You can have different rendering for mobile/non-mobile.

We are in the midst of everyone switching to mobile.

~~~
JoshCole
I know. I'm pointing out why this is a bad thing, because most people who
advocate for better mobile support on Hacker News don't see themselves as
advocating for a reduction in the quality of discussion and a reduction in the
depth and complexity of the articles being shared.

~~~
hyperpallium
Thanks, I see what you mean now. I didn't get it because I use a mobile
platform as desktop, but that's not generally true (so far).

------
MikkoFinell

      history | awk '{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl |  head -n10
         1	167  16.7%  git
         2	130  13%    ll
         3	94   9.4%   clear
         4	90   9%     make
         5	80   8%     cd
         6	57   5.7%   e
         7	52   5.2%   cat
         8	45   4.5%   man
         9	38   3.8%   valgrind
        10	37   3.7%   rm
    

Where ´e´ is an alias for ´vim´.

~~~
anon_mouse
I can copy/paste your statement and it works..

but when I try to save it as an alias method.. I keep getting error:

awk: cmd. line:1: {CMD[]++;count++;}END { for (a in CMD)print CMD[a] " "
CMD[a]/count*100 "% " a;} awk: cmd. line:1: ^ syntax error awk: cmd. line:1:
error: invalid subscript expression

I thought I would just escape the double quotes ", and things would work. :/
Any ideas?

~~~
arccy

      alias mostused='history | awk '\''{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}'\'' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl |  head -n10'

------
vram22
Linux has hundreds of them, in the various bin directories. Many are
interesting.

This shell snippet lists all the directories in $PATH, using less, so you can
page through them:

    
    
      for dir in `echo $PATH | sed 's/:/ /g'`
      do
          echo Listing dir: $dir
          ls -l $dir | nl
      done | less
    

I came across the watch command recently, which seems useful, and wrote
something like it in Python:

A Python version of the Linux watch command:

[https://jugad2.blogspot.in/2018/05/a-python-version-of-
linux...](https://jugad2.blogspot.in/2018/05/a-python-version-of-linux-watch-
command.html)

I've also been writing Python versions of some other Linux commands, and will
post about them here some time later.

Also, for saving (and then viewing) man pages (about commands or other
topics), without the formatting characters (such as ^H), on some Linux
distros, I find this useful:

m, a Unix shell utility to save cleaned-up man pages as text:

[https://jugad2.blogspot.in/2017/03/m-unix-shell-utility-
to-s...](https://jugad2.blogspot.in/2017/03/m-unix-shell-utility-to-save-
cleaned-up.html)

~~~
laumars
> _Also, for saving (and then viewing) man pages (about commands or other
> topics), without the formatting characters (such as ^H), on some Linux
> distros, I find this useful:_

^H is one of the two backspace characters (the other being ^?) depending on
which VT standard you're configured to use. So you shouldn't really need a
dedicate script to do that as it's just a problem between your pseudo-TTY
(Linux console) and your terminal emulator (PuTTY / iTerm / xterm / etc).

Thankfully both are easily configurable. However without knowing which
terminal emulator you're using I couldn't walk you throw configuring that. In
terms of the TTY; you can change the backspace character via the `stty`
command:

    
    
        stty erase [hit backspace on your keyboard]
    

Another thought is it might be a case that the TTY is largely configured
correctly already but you're overwriting your environmental variables with
non-standard values (eg the $TERM var with a value that differs from the
actual terminal you're using) which is causing the pager (`less` / `more` etc.
`man` will use this for the paging) to break the standard your terminal is
expecting. But either way, this is definitely a configuration problem rather
than something that should be fixed with additional parsing scripts.

~~~
recoil
> you shouldn't really need a dedicate script to do that

It isn't because the terminal is mis-configured and/or mis-interpreting those
characters, it's because these characters have historically been used in a
special way by troff's ascii output driver, as used by the man command.

Bold characters are "emulated" by outputting the character itself, followed by
^H, then by repeating the character, and underline is emulated by outputting _
(the underscore character) followed by ^H, followed by the character to be
underlined. This is the same way that bold/underline was achieved on a manual
typewriter or by old teletype terminals with paper output.

Pagers like "more" & "less" have in-built behaviour that knows how to
interpret these sequences and render bold or underline appropriately, and if
you "cat" the file your terminal would probably ignore them, but if you open a
file with those sequences in a text editor, you're going to see a bunch of
unnecessary ^H characters. The OP's script uses the "col" command to remove
the unnecessary ^Bs (and the preceding character) that troff has output.

By default, GNU groff doesn't actually output those sequences anymore and uses
ANSI escape codes instead. AFAIK many (most?) distributions actually compile
out the ANSI behaviour in favour of the old way though (because "more" and
"less" _don 't_ actually behave correctly with the ANSI characters by
default), but some don't, which breaks the script (it's broken in Cygwin, for
instance).

FWIW, if you need a fool-proof way to convert a man page to plain old ASCII
with no escapes at all, it's easiest just to redirect the output of "man" to a
file:

    
    
        man ls > ls.txt
    

The long-winded way (with groff) is something like:

    
    
        zcat /usr/share/man/man1/ls.1.gz | groff -man -Tascii -P -cbdu > ls.txt

~~~
vram22
You described the issue and cause better than I did :)

I didn't know about the ANSI behavior, interesting.

>FWIW, if you need a fool-proof way to convert a man page to plain old ASCII
with no escapes at all, it's easiest just to redirect the output of "man" to a
file:

> man ls > ls.txt

IIRC, even with that way, the control chars still appeared in the file (at
least on some Unix version), which is why I wrote the script in the first
place.

~~~
recoil
> the control chars still appeared in the file (at least on some Unix version)

That's a good point. My whole reply is a bit GNU-centric: the "col -bx"
solution should work with everything except groff in ANSI mode (looks like the
flag to go back to the standard troff behaviour is GROFF_NO_SGR [1][2], in
case anybody is interested).

[1] See:
[https://linux.die.net/man/1/grotty](https://linux.die.net/man/1/grotty) [2]
SGR is "Select Graphics Rendition", apparently:
[https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_(Select_G...](https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_\(Select_Graphic_Rendition\)_parameters)

------
gkya
If by terminal programs you mean command-line interface (CLI) programs, then
you'll never regret learning how core Unix commands work, in themselves and in
pipelines, and their POSIX-defined interfaces. I use these often: make grep
find sed xargs m4 cut tr cat tee sort uniq head tail pg/more/less ps
pkill/pgrep. My favourite among them is make, once you learn how it's meant to
be used, it's an incredibly useful and flexible tool.

Some other useful CLI programs that I use and are not part of POSIX are:
strace, perl, webalizer, rcs. RCS might be a mostly-forgotten VCS tool, but it
is very suitable for version-controlling projects that consist of single
files. I mostly use it for plain-text or Org-mode documents.

If you meant terminal-UI (TUI) programs, like top/htop, vi, etc., I don't
really use them. But I've used these in the past:

\- mutt: a very nice mail client

\- newsbeuter: RSS/ATOM feeds client

\- vi: I do occasionally use vi in some situations

In the past years I've started to use Emacs tools instead of these because
Emacs is a very rewarding, composable and comfortable working environment.
Still, I use CLI programs through Bash/shell-mode all the time, because it's
the most efficient way to do many tasks.

------
fusiongyro
The pipe viewer pv:
[https://ivarch.com/programs/pv.shtml](https://ivarch.com/programs/pv.shtml)

Great way to give you a progress bar on a long-running process from the
command line.

entr is useful for doing stuff on file change:

[http://www.entrproject.org/](http://www.entrproject.org/)

GNU parallel is like xargs, but in parallel:

[https://www.gnu.org/software/parallel/](https://www.gnu.org/software/parallel/)

------
veganjay
First of all, you might want to check out the subreddit:

/r/commandline
[https://www.reddit.com/r/commandline/](https://www.reddit.com/r/commandline/)

general commands

\- awk/grep/sed/wc - text file processing

\- convert (image magick) - image processing tool

\- cpulimit - limit the cpu usage of a process

\- fdupes - check for duplicate files and optionally remove them

\- pdftk - concatenate pdf files and more -
[https://www.pdflabs.com/tools/pdftk-the-pdf-
toolkit/](https://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/)

\- rsync - back up tool

\- tmux - terminal multiplexer - almost always my first install

\- tree - view directory contents in a tree format

\- zcat/zmore - display a file that is compressed (e.g. zmore
/var/log/syslog.2.gz)

security/reverse engineering:

\- binwalk - search binary images for embedded files

\- gdb + peda - debugger with extensions -
[https://github.com/longld/peda](https://github.com/longld/peda)

\- nmap - network scanning tool

\- radare2 - command line dissassembler -
[https://github.com/radare/radare2](https://github.com/radare/radare2)

\- scapy - network packet crafting -
[https://github.com/secdev/scapy](https://github.com/secdev/scapy)

\- tshark - network traffic analyzer

\- tcpdump - network traffic analyzer

\- xxd - hexdump tool

Bonus:

\- find - find files - I often use this to find files containing a string:

$ cat bin/findstring

#!/bin/sh

find . -type f -exec grep -i -l "$@" {} \;

~~~
laumars
If you're just using find to run grep against all files then you would be
better off using the recursive flag in grep instead

~~~
kjeetgill
I like the composition of tools, it lets you extend your usage pretty easily.
I personally run this 20 times a day: find -name '*.java' | xargs grep
'pattern'

~~~
laumars
But at least there you're searching for specific files. I was talking only
about running a find to launch an instance of grep for every file found.
That's more keystrokes to get a slower result.

For what it's worth, my biggest usage of find is similar to your java example
(except a different file extension). I also do do '-exec sed...') a lot too.

------
jweir
[https://github.com/junegunn/fzf](https://github.com/junegunn/fzf)

Fuzzy Finder for files, history and more. Integrates with Vim (and maybe other
editors). It is wicked fast.

~~~
mping
And if you use the bash/zsh functions the provide in the wiki, it becomes even
more useful for git, file opening, etc

------
ufmace
I basically live in vim and tmux when I'm doing development work. Tmux IMO
basically turns a terminal from a handy utility to a fully productive
workspace.

I switched to ripgrep for my grepping needs, I find it fast and the syntax and
output coloring handy.

Just found fastmod recently,
[https://github.com/facebookincubator/fastmod](https://github.com/facebookincubator/fastmod).
Very handy for doing bulk substitutions of strings in project directories - it
can prompt with a diff for every change and do full regexes, so you can try
out tricky things and make sure it isn't doing anything crazy before you let
it make 500 changes throughout your repo.

Also a fan of gitsh,
[https://github.com/thoughtbot/gitsh](https://github.com/thoughtbot/gitsh).
Helps out with using Git on the command line just the right amount IMO - just
avoiding the git prefix, tab completion, and a little syntax highlighting,
instead of trying to redo the whole interface.

I don't use it that much, but jq,
[https://stedolan.github.io/jq/](https://stedolan.github.io/jq/) is really
handy for slicing and dicing json data without diving into the complexity of
writing actual programs.

And on OS X, homebrew is indispensable for actually managing all of your CLI
programs.

I also have found this Google Drive cli handy, [https://github.com/odeke-
em/drive](https://github.com/odeke-em/drive). If you want to sync some but not
all of your Google Drive files, and only push and pull on command instead of
continuously, it's great.

------
poops
Since iTunes has been getting buggier and buggier for me (and I'm trying to
switch to programs that run on all platforms), I've replaced with...

beets [http://beets.io/](http://beets.io/) for library management

mpd [https://www.musicpd.org/](https://www.musicpd.org/) for serving music &

ncmpcpp [https://rybczak.net/ncmpcpp/](https://rybczak.net/ncmpcpp/) for
playing music (which I alias to `music`)

~~~
LeoPanthera
Combine with "abcde" for ripping CDs.

------
padthai
z and autojump are great, but if you want a full fledged file manager you
should try ranger:

[https://ranger.github.io/](https://ranger.github.io/)

For news, newsboat is quite nice:

[https://newsboat.org/](https://newsboat.org/)

For parsing and select actions over url links you can use urlview (it works
perfectly with pdftotext, newsboat, mutt, vim, w3m, etc.):

[https://github.com/sigpipe/urlview](https://github.com/sigpipe/urlview)

You can download webpages with httrack:

[http://www.httrack.com/](http://www.httrack.com/)

rsync is a fundamental tool to move files between computers or do backups,
forget about scp:

[https://rsync.samba.org/](https://rsync.samba.org/)

You can work with most pdf and ps (those that are not scanned images) using
your usual text tools,

[http://www.xpdfreader.com/](http://www.xpdfreader.com/)

There are even ready to go pdf + grep commands:

[https://pdfgrep.org/](https://pdfgrep.org/)

Somewhat meta, when you live in the terminal you need to be sure that you are
a bit POSIX compliant. shellcheck is a good tool for that:

[https://www.shellcheck.net/](https://www.shellcheck.net/)

Finally, there are a two packages that should be in any distributions (include
commands like vidir, parallel, watch, etc.):

[https://joeyh.name/code/moreutils/](https://joeyh.name/code/moreutils/)
[https://gitlab.com/procps-ng/procps/](https://gitlab.com/procps-ng/procps/)

------
kamranahmed_se
Some of them that I can't live without are

    
    
        - git-standup http://github.com/kamranahmedse/git-standup
    
        - z https://github.com/rupa/z
    
        - ZSH https://github.com/robbyrussell/oh-my-zsh
    
    

Apart from that, some that I use time to time

    
    
        - curl-size https://github.com/egoist/curl-size
    
        - ripgrep https://github.com/BurntSushi/ripgrep
    
        - jq https://github.com/stedolan/jq
    
        - asciinema https://github.com/asciinema/asciinema

~~~
roddds
Just notice that you linked to Oh My Zsh (which, granted, is essential) but
not to ZSH ([http://www.zsh.org/](http://www.zsh.org/))

~~~
meowface
>(which, granted, is essential)

Unless you belong to the Prezto or Antigen sects. :)

------
unlivingthing
If you like youtube-dl you should have a look at
[https://github.com/mafintosh/peerflix](https://github.com/mafintosh/peerflix)
!! (:

------
edgarvaldes
It is no longer updated, but I recommend
[https://inconsolation.wordpress.com/](https://inconsolation.wordpress.com/)
as a very good read. From the about page:

>This blog is intended as a quick look at terminal-based applications
available in Linux, and in some similar operating systems. Not only are these
ideal for modern, low-power and space-saving computers, but they go a long way
toward invigorating out-of-date hardware.

------
upofadown
Ever since I learned that USENET was still a thing for a current area of
interest:

slrn [http://slrn.sourceforge.net/](http://slrn.sourceforge.net/) for reading
newsgroups

My old fave (which I didn't even remember the name of) was

nn [http://www.nndev.org/](http://www.nndev.org/)

... which had too steep a (re)learning curve for reading just the one
newsgroup.

~~~
EamonnMR
Out of curiosity, where'd you sign up?

~~~
upofadown
[http://www.eternal-september.org/](http://www.eternal-september.org/)

------
brunosutic
Here are some of my favorites that I use daily:

\- tmux

\- mutt - email client

\- wyrd + remind - calendar

\- ledger - double-entry accounting tool

\- weechat + weeslack plugin - fully featured, super fast slack from the CLI

~~~
philsnow
+1 for remind and wyrd. Remind is really, really powerful. You can express
things like an appointment that fires "every 3 weeks starting May 4th, but if
that day falls on a weekend or holiday then {skip it, move it to the
following/preceding weekday that isn't a holiday}", and lots more. Wyrd is a
really nice console frontend to remind (I just found that there are graphical
frontends available too). Finally with rem2ics you can express really
complicated things in Remind and then export the results as an iCalendar-
compatible format and import that into whatever other calendar you want.

I used screen, remind+wyrd, mutt, and irssi (and even ledger) in school; I got
a job at a bigco that pretty much required me to use gmail and gcal, and I
stopped using console things as much. Lately I've been toying around with
moving my mail flow back into console / console-ish inside emacs.

This brings back all kinds of memories:
[https://www.roaringpenguin.com/wiki/index.php/Remind_use_cas...](https://www.roaringpenguin.com/wiki/index.php/Remind_use_case_2)

------
mgliwka
Meanwhile on twitter:
[https://twitter.com/b0rk/status/993165679833567233](https://twitter.com/b0rk/status/993165679833567233)

------
noufalibrahim
[https://www.passwordstore.org/](https://www.passwordstore.org/) for
passwords.

~~~
NVRM
oO

------
kaushalmodi
Emacs, tmux, tmuxp, ripgrep, eless[1], ncdu, exa (ls replacement. I often use
'exa --tree'), sed, awk, peco (I use this in aliases to select one or more
items from a command outputting multiple values), hugo, dtrx, textract (npm),
wget, shellcheck, rsync, htop.

I _heavily_ use git, but via Magit in Emacs.

[1]: My own little utility to use bare bones Emacs as less/pager:
[https://eless.scripter.co](https://eless.scripter.co)

~~~
h1d
Wow, peco is so convenient, now I don't have to keep trying to grep every
possibilities.

------
foobarchu
I find myself using noti a lot. It's effectively just a message generator that
can receive data over stdout or trigger manually. It uses whatever the most
appropriate notification method for your system is, so it feels very seemless.
I use it for long-running tasks where I don't really know how long it's going
to take.

[https://github.com/variadico/noti](https://github.com/variadico/noti)

------
jsmeaton
CSVkit -
[http://csvkit.readthedocs.io/en/1.0.3/](http://csvkit.readthedocs.io/en/1.0.3/)

A collection of tools for slicing and dicing csv files on the command line.

------
falcolas
A few I don't see otherwise listed:

    
    
        export MARKPATH=$HOME/.marks
        function jump {
            cd -P $MARKPATH/$1 2> /dev/null || (echo "No such mark: $1" && marks)
        }
        function mark {
            mkdir -p $MARKPATH; ln -s $(pwd) $MARKPATH/$1
        }
        function unmark {
            rm -i $MARKPATH/$1
        }
        function marks {
            ls -l $MARKPATH | sed 's/  / /g' | cut -d' ' -f9- && echo
        }
        _jump()
        {
            local cur=${COMP_WORDS[COMP_CWORD]}
            COMPREPLY=( $(compgen -W "$( ls $MARKPATH )" -- $cur) )
        }
        complete -F _jump jump
    

I used to use this one more; converted to vimwiki instead:
[http://todotxt.org/](http://todotxt.org/)

Local documentation:

    
    
        wget --recursive --level=5 --convert-links --page-requisites --wait=1 --random-wait --timestamping --no-parent $1
    

The only other ones which top the charts are jq, aws, curl, and docker.

------
apjana

      - googler: Google from the terminal
      - Buku: Bookmark manager like a text-based mini-web
      - nnn: The missing terminal file browser for X
      - bcal: Storage expression calculator
      - imgp: Multi-core batch image resizer and rotator
      - keysniffer: Linux kernel mode debugfs keylogger
      - ddgr: DuckDuckGo from the terminal 
      - pdd: Tiny date, time diff calculator

------
everybodyknows
_locate_ may be the most-overlooked timesaver on the GNU distro. For searches
of more than ~50000 directories, it's an order of magnitude faster than _find_
:

    
    
      $ time locate -0 /{opt,usr}/\*.gitignore |
        xargs -0 stat --format=%s | wc
          387     387    1225
    
      real	0m0.087s
    
      $ time find /{opt,usr} -name '.gitignore' -print0 2>/dev/null |
        xargs -0 stat --format=%s | wc
          387     387    1225
    
      real	0m0.748s
    

The speedup comes from reading a single database file rather than every
directory within the tree to be searched. If the files you want were last
touched today, a manually triggered rebuild of the database may be needed:

    
    
      $ sudo updatedb
    

The argument syntax for path specification of _locate_ I find more convenient
as well.

------
guilevi
MPS-Youtube is extremely useful if you don't mind the CLI and want to quickly
play a YouTube video. translate-shell if you're a language person. Very
complete interface to most popular translation services. atools(aunpack,
apack, als, etc) for quick archive manipulation if you're lazy.

~~~
pronik
mpv + youtube-dl plugin are also a nice combination, especially for live
streams.

~~~
zouhair
I prefer Streamlink[0] for live streams.

[0]: [https://github.com/streamlink](https://github.com/streamlink)

~~~
cobby
Could you please elaborate why you prefer streamlink over youtube-dl?

~~~
zouhair
I use them both, it is just youtube-dl is more suited for live streams and
youtube-dl is more suited for downloading non-live videos.

------
sevensor
Since all the good suggestions are taken, I want to mention a couple of
diversions:

fortune: prints something silly or thought-provoking. You can get extra
fortune cookie files or add your own.

cowsay: prints an ascii-art cow (or other creature) with a speech-bubble
filled with the text of your choice. You can pipe fortune into cowsay for
extra fun.

    
    
        $ fortune | cowsay
         ______________________________________ 
        / Publishing a volume of verse is like \
        | dropping a rose petal down the Grand |
        \ Canyon and waiting for the echo.     /
         -------------------------------------- 
                \   ^__^
                 \  (oo)\_______
                    (__)\       )\/\
                        ||----w |
                        ||     ||

~~~
e12e
These days, there's also:

[https://github.com/erkin/ponysay](https://github.com/erkin/ponysay)

My latest find is to use a combination of weechat and wee-slack for most of my
slack usage (it's note quite there when it comes to editing, or in-line
reactions). But works well for the chat part:

[https://weechat.org/](https://weechat.org/)

[https://github.com/wee-slack/wee-slack](https://github.com/wee-slack/wee-
slack)

As a former BitchX and sometime irssi user, weechat feel cozy. And it doesn't
eat all your ram just for chat.

------
hypertexthero
The Fuck - [https://github.com/nvbn/thefuck](https://github.com/nvbn/thefuck)

------
bgongfu
Tetris:

[https://github.com/basic-
gongfu/cixl/blob/master/examples/ci...](https://github.com/basic-
gongfu/cixl/blob/master/examples/cixtris.cx)

PNG viewer:

[https://github.com/basic-
gongfu/cximage/blob/master/examples...](https://github.com/basic-
gongfu/cximage/blob/master/examples/pngans.cx)

Linux/64 binaries may be found here:

[https://github.com/basic-
gongfu/cxbin/blob/master/linux64](https://github.com/basic-
gongfu/cxbin/blob/master/linux64)

------
TeMPOraL
Emacs.

Just ensure you're running a 256-bit color terminal emulator, and for most
uses it doesn't even differ that much from the GUI version. Recently I've been
doing a lot of work by SSH-ing to my desktop machine from a small netbook and
using the terminal Emacs client. If you run Emacs in server mode, the
transition is so smooth that at this point, I don't bother getting out of bed
if I need to work on something late in the evening, I just take the netbook
and SSH over.

~~~
gkya
If you don't have a reason to use Emacs from the terminal emulator, use the
GUI. And for SSH, it's very hard to reject Tramp. One must is to make it less
verbose though: (setq tramp-verbose 1). Then it becomes faster (at least in my
perception) and way less noisy.

~~~
philsnow
I find using emacs in the terminal less bothersome on osx because of osx's
inane out of the box window management; I can replace it completely with
managing emacs frames in screen and that experience doesn't change when I move
between platforms.

------
maxdata
Piggybacking on OP's suggestion of youtube-dl, i have this alias for quickly
grabbing the audio-only version of a youtube video. (I use it when I come
across a song on youtube that I can't find for sale or streaming anywhere
else)

alias dl-audio='youtube-dl --extract-audio --audio-format mp3'

If you have ffmpeg installed, just drop the video ID after dl-audio, and
you'll get an mp3 of the highest quality audio stream available for the video.

~~~
e12e
I wouldn't specify mp3, unless you need to support legacy/device playback -
there are often better audio versions available (ogg, aac etc).

------
BeetleB
\- Midnight commander - Best file manager ever

\- htop - a graphical top

\- xonsh: A shell written in Python. You can now write your shell scripts in
Python (with access to any Python library)

\- mplayer: Video player

------
jamestomasino
There's so many programs and scripts I use it's hard to keep them all
straight. So, instead of trying I just exported a list of every command in my
history that I've used at least twice:

[https://gist.github.com/jamestomasino/9d912b409e5b6067ac233e...](https://gist.github.com/jamestomasino/9d912b409e5b6067ac233e62e1765c96)

Also of interest, my custom functions:

[https://github.com/jamestomasino/dotfiles/tree/master/bash/....](https://github.com/jamestomasino/dotfiles/tree/master/bash/.functions)

And finally, my OSX & Linux Mint install scripts which include a lot of great
app packages:

[https://github.com/jamestomasino/dotfiles/blob/master/osxset...](https://github.com/jamestomasino/dotfiles/blob/master/osxsetup.sh)
[https://github.com/jamestomasino/dotfiles/blob/master/mintse...](https://github.com/jamestomasino/dotfiles/blob/master/mintsetup.sh)

------
cdancette
ncdu to analyze disk space and find huge folders you can clean

And `z` (the zsh plugin) to cd into your most common directories

~~~
veganjay
Thanks for sharing - I did not know about ncdu.

I typically do a series of "du -s -h * | sort -h" and this simplifies things.

~~~
philsnow
wow, learned about that flag to sort today, thanks. I've been just doing "du
-s | sort -n"

------
chicocode
fpp
[http://facebook.github.io/PathPicker/](http://facebook.github.io/PathPicker/)

~~~
DataWorker
Rad

------
NVRM
micro, mc, ag silver searcher, stat, find, aria2c, xev, w3m, wmctrl, nohup,
xdotool, docker, php, ffmpeg, phantomjs, du, ls [From my history file, all
others are homemade scripts and little functions in .bashrc]

~~~
v_lisivka
ncdu is much better than just du.

~~~
NVRM
Thanks. Will try it in details. Currently, it is taking like really forever to
scan my bunchs of old school hard drives! du options are easy to remember,
ergonomy first^ May I suggest a good one to remember `ls -ltrapR` <\- It
always kill anyone aside ;)

~~~
NVRM
And it was an amazing jump in productivity when i forced myself to learn
`stat` shortcuts. Recommended!

------
cyberjunkie
tmux [https://github.com/tmux/tmux/wiki](https://github.com/tmux/tmux/wiki)

glances
[https://nicolargo.github.io/glances/](https://nicolargo.github.io/glances/)

rtv [https://github.com/michael-lazar/rtv](https://github.com/michael-
lazar/rtv)

rainbowstream
[https://github.com/orakaro/rainbowstream](https://github.com/orakaro/rainbowstream)

discurses
[https://github.com/topisani/Discurses](https://github.com/topisani/Discurses)

telegram-cli [https://github.com/vysheng/tg](https://github.com/vysheng/tg)

------
dwwmmn
Since a couple people mentioned z and autojump: I recently discovered z and
found it so useful I ported it to Windows/Powershell.

[https://github.com/dwwmmn/z.ps1](https://github.com/dwwmmn/z.ps1)

It's a little simplistic for now but I hope it helps someone.

------
btschaegg
For me personally, I guess netcat, socat, tcpdump and SSH (for tunneling)
qualify the most. I'm working in a Windows environment where I'm usually not
allowed to install new software, and I miss those by far the most.

Often, I need to do a test run of something which involves slightly rerouting
network traffic and I'll spend half a day hacking together some horrible
"solution" that I could literally have done in 3 lines of bash code on a UNIX-
like system. Maybe throw hexdump for looking at binary stuff in there too.

Edit: Oh, and of course GDB! If only I could have the accumulated days of log
forensics back that were done just because it's still _faster_ to do that
instead of getting the visual studio debugger to work remotely. Whatever
happened to KISS? -_-

------
e12e
For Windows, I'd like to point to [http://scoop.sh](http://scoop.sh) as
mentioned here:

[https://news.ycombinator.com/item?id=17019197](https://news.ycombinator.com/item?id=17019197)

It's a bit like a mix of (x)stow and apt for Windows. Or the good parts of
arch aur with binary distribution.

Should probably also mention that I'm experimenting with asdf as a version
manager - to avoid a long list of setup in bashrc to adjust paths to various
interpreters. It follows a lot of best practices that various dedicated
version managers seem to pick up eventually:

[https://github.com/asdf-vm/asdf](https://github.com/asdf-vm/asdf)

------
crasch4
* exiftool - photo metadata editing tool

* dcraw - RAW photo processing tool

* imagemagick - image processing library

* pandoc - convert one file into another

* diceware - random word generator (useful for creating passwords)

* csvtomd - convert csv files to markdown tables

* newsbeuter - RSS reader

* zathura - pdf viewer

* weechat - irc client

* ncdu - interactive disk usage

* ranger - file manager

* mpd - music player daemon

* vimpc - vim inspired client for mpd

------
hoppelhase
bat [https://github.com/sharkdp/bat](https://github.com/sharkdp/bat)

exa [http://the.exa.website](http://the.exa.website)

Both are good additions.

------
pvaldes
Some time ago I wrote just for fun this couple of lines:

> What else I'm missing out on

echo 'Currently there are ' $(ver=(/bin /sbin /usr/bin /usr/sbin) && ls
${ver[*]} | wc -l) 'commands installed and available in the system'

This prints the man page of 3 random commands. One by one. Is a way to
discover a few new commands each day. To go to the next command and exit press
q. I hope you enjoy it.

commandoftheday=(/bin /sbin /usr/bin /usr/sbin) && ls ${commandoftheday} |sort
-R |head -3 |xargs man '{}'

------
Dewep
GCE (Global Commands Execution), which is a desktop application that provides
a single context to manage and run multiple scripts.

[https://github.com/Dewep/GCE](https://github.com/Dewep/GCE)

Why?

As web applications are being split in micro services and independant
entities, it becomes harder and harder to setup a local dev environment and
you have to handle dozen of shell terminals.

GCE aims to take that pain away by offering you the ability to configure the
setup of your projects once and run it in the blink of an eye.

------
dredmorbius
A/V: mplayer, aa-xine, surfraw, mpsyt, youtube-dl, cdparanoia, oggenc

Network mgt: ipcalc, mtr, wireshark, nc

Comms & Info: mutt, w3m, irssi, screen (though if you're just starting: tmux),
swaks (smtp swiss army knife),

Code & Tasks: make, gawk, sponge (moreutils generally), xclip (pbcopy OSX),
at, batch, and cron,

Calculators: units (GNU, not BSD), bc, & dc,

Editing & Docs: pandoc, vim, less ("&" filters!),

Files: curl, wget, scp, rsync, & lftp, mc, column, tree,

Images: mogrify / convert (ImageMagick),

Sysadmin: apt, grep-dpkg, apt-file, auto-apt, pstree,

------
urmish
I just started using cmus and it works great. Also loads up the music library
pretty fast.

tmux, neovim are great together (after some configuration.)

Mplayer seems better than mpv. They need configuration though.

htop/top are pretty useful for figuring out which applications are taking up
cpu resources.

cpufreq-utils are useful to set max/min cpu speeds if you're running low on
laptop battery.

meld is an amazing diff tool though not command line. vimdiff is useful too.

------
timundo
wuzz: [https://github.com/asciimoo/wuzz](https://github.com/asciimoo/wuzz)

------
ktilcu
I love tig [https://github.com/jonas/tig](https://github.com/jonas/tig)

------
Fazel94
I can't live without `sudo` :p

    
    
        - `ffmpeg` one utility for video manipulation to rule them all.
    
        - `ping` to check whether I am connected to the internet or not.
    
        - `curl -vvv maktabkhooneh.org` to check where is the connection problem happens.
    
        - `howdoi` search StackOverflow for snippets to solve your problem from the command line.

------
0xdeadbeefbabe
\- ncdu for disk usage and deleting extra stuff

------
O_H_E
xrandr: _Manege external monitors_

zsh: _Stepping up your terminal game_ \- [https://github.com/robbyrussell/oh-
my-zsh](https://github.com/robbyrussell/oh-my-zsh)

tmux: _A terminal multiplexer, aka turns your terminal to a minimalist
workspace_ (the only sane way I found to copy terminal output without using a
mouse)

howdoi: _Search stachoverflow /stackexchange from the CLI_ \-
[https://github.com/gleitz/howdoi/](https://github.com/gleitz/howdoi/)

nmtui: _WIFI /Networking from the terminal_ \-
[https://github.com/heftig/NetworkManager](https://github.com/heftig/NetworkManager)

bluetoothctl: _Bluetooth from the terminal_

___________________

Lists for exploration:

\-
[https://en.wikipedia.org/wiki/List_of_Unix_commands](https://en.wikipedia.org/wiki/List_of_Unix_commands)

\-
[https://wiki.archlinux.org/index.php/List_of_applications](https://wiki.archlinux.org/index.php/List_of_applications)

\- [https://github.com/alebcay/awesome-
shell](https://github.com/alebcay/awesome-shell)

\- [https://github.com/agarrharr/awesome-cli-
apps](https://github.com/agarrharr/awesome-cli-apps)

\- [https://github.com/herrbischoff/awesome-command-line-
apps](https://github.com/herrbischoff/awesome-command-line-apps)

(The github links seems similar, but there are some differences indeed)

~~~
O_H_E
Apperanlty I can't make a list of urls on HN, WTF

------
imron
jq - amazingly useful for processing JSON

~~~
johnbellone
Ah, you beat me to it!

------
hyperpallium
REQUEST: jq is great for json - but is there a "jq for xml"?

Some webservices are still only available in xml (e.g. uv levels). I currently
use XMLStarlet for xml in the terminal. There are extra annoyances in xml that
you can't avoid (like namespaces), but it could be a lot closer to jq.

~~~
eigengrau
I’ve used
[https://github.com/ericchiang/xpup](https://github.com/ericchiang/xpup) for
this a few times.

~~~
hyperpallium
Thanks, seems the right idea, but browsing the code, _decode_ just interprets
a single xpath expression. While that is useful (and I've used xpath from the
CL like before), I found I quickly needed to be able to chain them together
etc.

pup
([https://github.com/ericchiang/pup/blob/master/README.md](https://github.com/ericchiang/pup/blob/master/README.md))
which apparently inspired xpup does seem to have this, e.g. chaining, but
unfortunately it uses css selectors instead of xpath.

------
vram22
The Decorate-Sort-Undecorate idiom (a.k.a Schwartzian Transform) is useful:

[https://www.google.co.in/search?q=decorate+sort+undecorate+i...](https://www.google.co.in/search?q=decorate+sort+undecorate+idiom+in+unix+command+line)

------
tfe
pianobar - command line Pandora client

[http://6xq.net/pianobar/](http://6xq.net/pianobar/)

[https://github.com/PromyLOPh/pianobar](https://github.com/PromyLOPh/pianobar)

------
boyter
Tmux and ripgrep are two that I use daily. I used to use cloc then switched to
tokei, then to my own scc which I use frequently along with lc. Hyperfine is
something I have been using a lot and despite having ripgrep I still use grep
often with xargs.

------
bovermyer
`makearms`, a random SVG heraldry generator.

I'm biased, though, because I'm the author.
[https://github.com/ironarachne/heraldry](https://github.com/ironarachne/heraldry)

------
sairamkunala
rg => (ripgrep) alternative to ack and grep.

~~~
SOLAR_FIELDS
There’s also ag (the silver searcher)

~~~
boyter
I must confess based on the strength of the argument buruntsushi had with the
Ripgrep comparison I switched from ag to rg and have not looked back. I was a
daily ag user but I don’t need the advanced regex support and I do like the
speed.

------
skfist
_Written in Python:_

\- subliminal: Find & Download subtitles
[https://github.com/Diaoul/subliminal](https://github.com/Diaoul/subliminal)

------
dstdk
I was going to say xterm.. But I guess ssh, git, vim, gcc, make, node, tar,
docker, elinks, mutt ls, ps, cp, mv, mkdir, timidity, minicom, tmux, diff, jq
and some I can't recall right now

------
jeroenjanssens
mdp - A command-line based markdown presentation tool -
[https://github.com/visit1985/mdp](https://github.com/visit1985/mdp)

------
simon_acca
gron, a simple tool to make JSON greppable:
[https://github.com/tomnomnom/gron](https://github.com/tomnomnom/gron)

------
jlgaddis
lastpass-cli ("LastPass command line interface tool") [0], with several
aliases:

    
    
      $ alias | grep lpass
      lp=lpass
      lpls='lpass ls'
      lppw='lpass show -c -G --password'
      lpsh='lpass show -G'
      lpst='lpass status'
    
    

[0]: [https://github.com/lastpass/lastpass-
cli](https://github.com/lastpass/lastpass-cli)

------
yread
cd

because I never had to lookup how to use it

EDIT: hm it doesn't even have a man/info page. Where can you learn about "cd"
or "cd -", then?!

~~~
kamranahmed_se
`cd` is not a command; it is built into your shell.

Some systems, like OS X and CentOS, map the cd man page to builtin which lists
all the shell builtins and lets you know you should look at your shell's man
page.

------
pedrorijo91
[https://github.com/wting/autojump](https://github.com/wting/autojump)

------
templon
Didn't see anybody mention "miller" yet ... pipe/grep/cut/awk etc for CSV
files, really rocks.

------
cmcginty
sponge is great when you want to read and write to the same file:

    
    
        cat file.txt | grep -v secret | sponge file.txt

------
DanBC
youtube-dl, get_iplayer.

I used to enjoy "orpheus", and MP3 player. That's ncurses, which I think
counts. [http://thekonst.net/orpheus](http://thekonst.net/orpheus)

------
kup0
musikcube: a cross-platform, terminal-based music player
[https://github.com/clangen/musikcube](https://github.com/clangen/musikcube)

------
lchsk
htop and xstarter (disclaimer, I'm the author of the latter)

~~~
bananicorn
Damn, xstarter looks neat! I'll try how well it plays with the suckless
terminal :)

~~~
lchsk
Thanks! I think it works well with st!

------
ninguem2
pdftk. If you find yourself needing to extract pages, split or merge pdf
documents, this is wonderful.

~~~
coolutils
Split PDF files by pages, blank pages, file size, bar codes, bookmarks.
[https://www.coolutils.com/download/PDFSplitter.exe](https://www.coolutils.com/download/PDFSplitter.exe)

------
vowelless
Some less mentioned ones : tig, htop

~~~
purerandomness
tig is the best underrated git frontend out there.

------
jimjimjim
\- emacs

\- mc

\- git

\- ssh

------
nextos
emacs

screen

notmuch, isync

powertop

parallel, ag

------
thomas_mcn
youtube-dl dvdbackup

------
billconan
I like ffmpeg

------
dingleberry
vifm

------
sneak
byobu

------
giahoang
ZSH

------
roadbeats
ranger mocp rofi feh urxvt

~~~
silasb
ranger looks awesome... Going to try to integrate that into my workflow.
Thanks.

------
carc1n0gen
rainbowstream

A python cli tool for twitter

------
ablx_
tldr ([https://github.com/tldr-pages](https://github.com/tldr-pages)) since I
always forget the damn parameters for tar & it's more convinient than man

------
turkeybacongod
like... tmux?

------
kenrose
q

Parse CSV with SQL

------
shiado
nettop

------
alifbae
youtube-dl

~~~
dredmorbius
Add to your repertoire: mpsyt.

------
sneak
pom

------
gcb0
tig

~~~
orcs
Link? What's if for?

~~~
maze-le
Its a CLI interface for git.

[https://github.com/jonas/tig](https://github.com/jonas/tig)

~~~
ciupicri
I think TUI as in Text User Interface (similar to GUI) would be a more
appropriate term than CLI. git is CLI, tig is TUI and gitk is GUI.

------
lowry
st

------
Froyoh
That is all.

