Table of contents
Quick install
I don't know about you, but I don't enjoy spending lots of time installing stuff.
So here is my executive summary
PROGRAMS="hub httpie ripgrep bat fzf fd fd-find jq autojump direnv tig tmux neovim exa just lazygit jump"
NPM="how-2 tldr"
export INSTALLER="sudo apt-get" # on Debian/Ubuntu
export INSTALLER="something else" # on another Linux
export INSTALLER="brew" # on macOS
for program in $PROGRAMS ; do $INSTALLER install $program ; done
for program in $NPM ; do npm install -g $program ; done
You may want to configure your .profile
## Put in .bash_profile or .zshrc
alias ls=exa
alias cat=bat
Try, adopt or uninstall
Try out the CLI tools. If you don't like them, uninstall them the same way
PROGRAMS="neovim exa"
export INSTALLER="brew" # on macOS
for program in $PROGRAMS ; do $INSTALLER uninstall $program ; done
This being done, let's move on to the tools!
The 15 Command Line Tools which Spark Joy in Your Terminal
*tldr-pages/tldr: π Collaborative cheatsheets for console commands
A must have
The man page is too long, didn't read.
Replace $ man git-checkout by $ tldr git-checkout
You will find what you need in 5s or less, 80% of the time or more
Collaborative cheatsheets for console commands π.
What is tldr-pages?
The tldr-pages project is a collection of community-maintained help pages
for command-line tools, that aims to be a simpler, more approachable complement
to traditional man pages.
Maybe you're new to the command-line world. Perhaps you're just a little rusty or can't always recall the arguments for commands like lsof, or tar?
It certainly doesn't help that, in the past, the first option explained in man tar was:
$ man tar
...
-b blocksize
Specify the block size, in 512-byte records, for tape drive I/O.
As a rule, this argument is only needed when reading from or writing to tape drives,
and usually not even then as the default block size of 20 records (10240 bytes) is very common.
...
There is room for simpler help pages focused on practical examples.
How about:
Screenshot of the tldr client displaying the tar command.
This repository is just that: an ever-growing collection of examples
for the...
stedolan/jq: Command-line JSON processor
Unix scripts are based on the idea that you have a stdout with lines of outputs.
How do you autoamte things if you have JSON instead? (and JSON is everywhere)
jq is the answer
Command-line JSON processor
jq
jq is a lightweight and flexible command-line JSON processor akin to sed,awk,grep, and friends for JSON data. It's written in portable C and has zero runtime dependencies, allowing you to easily slice, filter, map, and transform structured data.
Documentation
Installation
Prebuilt Binaries
Download the latest releases from the GitHub release page.
Docker Image
Pull the jq image to start quickly with Docker.
Run with Docker
Example: Extracting the version from a package.json file
docker run --rm -i ghcr.io/jqlang/jq:latest < package.json '.version'
Example: Extracting the version from a package.json file with a mounted volume
docker run --rm -i -v "$PWD:$PWD" -w "$PWD" ghcr.io/jqlang/jq:latest '.version' package.json
Building from source
Dependencies
- libtool
- make
- automake
- autoconf
Instructions
git submodule update --init # if building from git to get
...
direnv/direnv: unclutter your .profile
My .profile is horrible so I'm looking forward to try this one
direnv -- unclutter your .profile
Built with Nix
Packaging status
latest packaged version(s)
Support room on Matrix
direnv is an extension for your shell. It augments existing shells with a
new feature that can load and unload environment variables depending on the
current directory.
Use cases
- Load 12factor apps environment variables
- Create per-project isolated development environments
- Load secrets for deployment
How it works
Before each prompt, direnv checks for the existence of a .envrc file (and
optionally a .env file) in the current
and parent directories. If the file exists (and is authorized), it is loaded
into a bash sub-shell and all exported variables are then captured by
direnv and then made available to the current shell.
It supports hooks for all the common shells like bash, zsh, tcsh and fish.
This allows project-specific environment variables without cluttering the
~/.profile file.
Because direnv is compiled into a single static executable, it is fast enough
to be unnoticeable on each prompt. It is...
jonas/tig: Text-mode interface for git
Text-mode interface for git
Tig: text-mode interface for Git
What is Tig?
Tig is an ncurses-based text-mode interface for git. It functions mainly
as a Git repository browser, but can also assist in staging changes for
commit at chunk level and act as a pager for output from various Git
commands.
Bugs and Feature Requests
If you are sending a bug report, please include the following information:
-
What Tig and ncurses versions are you using?
(tig -v)
-
What system do you have?
(uname -a, lsb_release -a)
-
What Git version are you using?
(git -v)
tmux/tmux: terminal multiplexer
tmux is a terminal multiplexer: it enables a number of terminals to be created, accessed, and controlled from a single screen. tmux may be detached from a screen and continue running in the background, then later reattached.
Welcome to tmux!
tmux is a terminal multiplexer: it enables a number of terminals to be created
accessed, and controlled from a single screen. tmux may be detached from a
screen and continue running in the background, then later reattached.
This release runs on OpenBSD, FreeBSD, NetBSD, Linux, macOS and Solaris.
Dependencies
tmux depends on libevent 2.x, available from this
page.
It also depends on ncurses, available
from this page.
To build tmux, a C compiler (for example gcc or clang), make, pkg-config and a
suitable yacc (yacc or bison) are needed.
Installation
Binary packages
Some platforms provide binary packages for tmux, although these are sometimes
out of date. Examples are listed on
this page.
From release tarball
To build and install tmux from a release tarball, use:
./configure && make
sudo make install
tmux can use the utempter library to update utmp(5), if it is...
santinic/how2: stackoverflow from the terminal
StackOverflow being such a massive part of a developer workflow, why not automating it?
how2: AI for your Terminal
how2 finds the simplest way to do something in a unix shell
It's like man, but you can query it in natural language. It uses a mix of AI code-completion and StackOverflow search.
It effectively replaces Chrome => New Tab => Google => Click on StackOverflow => Scroll Down to first answer.
Go to how2terminal.com for more info.
how2 AI for the Command-Line
Demo video
v5.mp4
Install
MacOSX (via HowBrew):
brew tap how2terminal/how2
brew install how2
With NPM:
If you install it without sudo, then you have to run it with npx how2 or alias the command manually.
Ubuntu/Debian:
Download latest .deb and then run:
wget how2terminal.com/how2.deb
sudo dpkg -i how2.deb
Binaries:
Go to the latest release and download the binaries.
Usage
By default, how2 uses an external AI server to find the best unix command line suggestion
If you add the -s...
BurntSushi/ripgrep : like grep, but better
ripgrep recursively searches directories for a regex pattern while respecting your gitignore
ripgrep recursively searches directories for a regex pattern while respecting your gitignore
ripgrep (rg)
ripgrep is a line-oriented search tool that recursively searches the current
directory for a regex pattern. By default, ripgrep will respect gitignore rules
and automatically skip hidden files/directories and binary files. (To disable
all automatic filtering by default, use rg -uuu.) ripgrep has first class
support on Windows, macOS and Linux, with binary downloads available for every
release. ripgrep is similar to
other popular search tools like The Silver Searcher, ack and grep.
Build status
Crates.io
Packaging status
Dual-licensed under MIT or the UNLICENSE.
CHANGELOG
Please see the CHANGELOG for a release history.
Documentation quick links
Screenshot of search results
A screenshot of a sample search with ripgrep
Quick examples comparing tools
This example searches the entire
Linux kernel source tree
(after running make defconfig && make -j8) for [A-Z]+_SUSPEND, where
all matches must be words. Timings were collected on a system...
sharkdp/bat: A cat(1) clone with wings.
Syntax highlighting for a large number of programming and markup languages, because why not?
You can alias it
$ alias cat=bat
A cat(1) clone with wings.
junegunn/fzf: A command-line fuzzy finder
Makes looking for a file as easy as in Visutal Studio Code or IntelliJ
πΈ A command-line fuzzy finder
fzf merch
Show your love for fzf -- T-shirts, mugs, and stickers now available
commitgoods.com/collections/fzf
fzf is a general-purpose command-line fuzzy finder.
It's an interactive filter program for any kind of list; files, command
history, processes, hostnames, bookmarks, git commits, etc. It implements
a "fuzzy" matching algorithm, so you can quickly type in patterns with omitted
characters and still get the results you want.
Highlights
-
Portable -- Distributed as a single binary for easy installation
-
Fast -- Optimized to process millions of items instantly
-
Versatile -- Fully customizable through an event-action binding mechanism
-
All-inclusive -- Comes with integrations for Bash, Zsh, Fish, Vim, and Neovim
Table of Contents
sharkdp/fd: like find, but better
A simple, fast and user-friendly alternative to 'find'
A simple, fast and user-friendly alternative to 'find'
fd
CICD
Version info
[δΈζ]
[νκ΅μ΄]
fd is a program to find entries in your filesystem
It is a simple, fast and user-friendly alternative to find
While it does not aim to support all of find's powerful functionality, it provides sensible
(opinionated) defaults for a majority of use cases.
Installation β’ How to use β’ Troubleshooting
Features
- Intuitive syntax:
fd PATTERN instead of find -iname '*PATTERN*'.
- Regular expression (default) and glob-based patterns.
-
Very fast due to parallelized directory traversal.
- Uses colors to highlight different file types (same as
ls).
- Supports parallel command execution
- Smart case: the search is case-insensitive by default. It switches to
case-sensitive if the pattern contains an uppercase
character*.
- Ignores hidden directories and files, by default.
- Ignores patterns from your
.gitignore, by default.
- The command name is 50% shorter* than
find :-).
Demo
Demo
How to use
First, to...
wting/autojump
A cd command that learns - easily navigate directories from the command line
A cd command that learns - easily navigate directories from the command line
NAME
autojump - a faster way to navigate your filesystem
DESCRIPTION
autojump is a faster way to navigate your filesystem. It works by
maintaining a database of the directories you use the most from the
command line.
Directories must be visited first before they can be jumped to.
USAGE
j is a convenience wrapper function around autojump. Any option that
can be used with autojump can be used with j and vice versa.
-
Jump To A Directory That Contains foo:
-
Jump To A Directory That Contains foo, Preferring Child Directories:
You can prioritize child directories over matches in the databases via
-
Open File Manager To Directories (instead of jumping):
Instead of jumping to a directory, you can open a file explorer
window (Mac Finder, Windows Explorer, GNOME Nautilus, etc.) to the
directory instead.
Opening a file manager to a child directory...
inconshreveable/ngrok: Introspected tunnels to localhost
You have your web app working on localhost, the CI is broken and you can't share your work with your colleagues.
Except that with ngrok, you can!
Unified ingress for developers
ngrok - Unified Ingress for Developers
https://ngrok.com
ngrok Community on GitHub
If you are having an issue with the ngrok cloud service please open an issue on the ngrok community on GitHub
This repository is archived
This is the GitHub repository for the old v1 version of ngrok which was actively developed from 2013-2016.
This repository is archived: ngrok v1 is no longer developed, supported or maintained.
Thank you to everyone who contributed to ngrok v1 it in its early days with PRs, issues and feedback. If you wish to continue development on this codebase, please fork it.
ngrok's cloud service continues to operate and you can sign up for it here: https://ngrok.com/signup
What is ngrok?
ngrok is a globally distributed reverse proxy that secures, protects and accelerates your applications and network services, no matter where you run them. You can think of ngrok as the front door to your...
github/hub:
A command-line tool that makes git easier to use with GitHub.
A command-line tool that makes git easier to use with GitHub.
hub is a command line tool that wraps git in order to extend it with extra
features and commands that make working with GitHub easier.
For an official, potentially more user-friendly command-line interface to GitHub
see cli.github.com and
this comparison.
This repository and its issue tracker is not for reporting problems with
GitHub.com web interface. If you have a problem with GitHub itself, please
contact Support.
Usage
$ hub clone rtomayko/tilt
#=> git clone https://github.com/rtomayko/tilt.git
# or, if you prefer the SSH protocol:
$ git config --global hub.protocol ssh
$ hub clone rtomayko/tilt
#=> git clone git@github.com:rtomayko/tilt.git
See usage examples or the full reference
documentation to see all available commands
and flags.
hub can also be used to make shell scripts that directly interact with the
GitHub API.
hub can be safely aliased as git, so you can type $ git <command> in the...
Build your own CLI tools, but maybe not in Bash
Command-line tools are great to automate and simplify your developer workflow.
Tools written by others are good, but why would you not write your own tools?
I have a strong opinion weakly held on this topic:
After 15 years of trying to program in Bash and being stuck at trials and errors, I think it's time to retire Bash.
Why not using your favorite programming language instead?
I found they are 10x time better than Bash.
Python, Go and JavaScript are all good choices to write a CLI tool.
Now my favorite language being Kotlin, I wanted to write a starter project for my own CLI tools using Kotlin multiplatform.
So if you allow me this shameless plug, have a look at the kotlin-cli-starter GitHub template
Life is too short for Bash programming
A starter project to build command-line tools in Kotlin Multiplatform
Contains a re-implementation of a real world CLI tool: git-standup
jmfayard_kotlin-cli-starter__Life_is_too_short_for_Bash_programming_and_Telegram_and_GitHub_Desktop
Installation
You can install using one of the options listed below
| Source |
Command |
| Node |
npm install -g kotlin-cli-starter |
| Installer |
curl -L https://raw.githubusercontent.com/jmfayard/kotlin-cli-starter/main/installer.sh | sudo sh |
| Tests |
./gradlew allTests |
| Kotlin All Platforms |
Run ./gradlew allRun
|
| Kotlin JVM |
Run ./gradlew run
|
| Kotlin Native |
Run ./gradlew install then $ git standup
|
| Kotlin Node.JS |
Run ./gradlew jsNodeRun
|
Why?
Being able to write your own command-line tools is a great skill to have. Automate all the things!
You can write the CLI tools in Kotlin and reap the benefits of using
- a modern programming language
- modern IDE support
- modern practices such as unit testing and continuous integration
- leverage Kotlin multiplatform libraries
- run your code on the JVM and benefit from a wealth of Java libraries
- or build a native executable, which starts very fast and...
Any cool tool that I'm missing?
No such list would be ever complete, so please add your recommandation in the comments.
Updates from my readers
jesseduffield/lazygit simple terminal UI for git commands
lazygit is a very cool git client
simple terminal UI for git commands
See the demo
[γγ¬γΌγ ]
casey/just: π€ Just a command runner
Inspired by make
π€ Just a command runner
Table of ContentsβοΈ
just
just is a handy way to save and run project-specific commands.
This readme is also available as a book. The
book reflects the latest release, whereas the
readme on GitHub
reflects latest master.
(δΈζζζ‘£ε¨ θΏι
εΏ«ηθΏζ₯!)
Commands, called recipes, are stored in a file called justfile with syntax
inspired by make:
screenshot
You can then run them with just RECIPE:
$ just test-all
cc *.c -o main
./test --all
Yay, all your tests passed!
just has a ton of useful features, and many improvements over make:
-
just is a command runner, not a build system, so it avoids much of
make's complexity and idiosyncrasies
No need for .PHONY recipes!
-
Linux, macOS, Windows, and other reasonable unixes are supported with no
additional dependencies. (Although if your system doesn't have an sh
you'll need to choose a different shell.)
...
gsamokovarov/jump: Jump helps you navigate faster by learning your habits. βοΈ
An alternative to cd that feels like it can read your mind
Jump helps you navigate faster by learning your habits. βοΈ
[releases]
Jump
Jump integrates with your shell and learns where you go. It tracks the directories you visit and lets you jump to the right one with just a few fuzzy-typed characters.
Demo
Installation
Packages are available on the following platforms:
Platform |
Command |
macOS |
brew install jump or port install jump
|
Linux |
sudo snap install jump |
Nix |
nix-env -iA nixpkgs.jump |
Go |
go install github.com/gsamokovarov/jump@latest |
Linux distribution packages
| Distribution |
Command |
| Arch |
sudo yay -S jump |
| Ubuntu / Debian |
wget https://github.com/gsamokovarov/jump/releases/download/v0.67.0/jump_0.67.0_amd64.deb && sudo dpkg -i jump_0.67.0_amd64.deb |
| Fedora |
wget https://github.com/gsamokovarov/jump/releases/download/v0.67.0/jump-0.67.0-1.x86_64.rpm && sudo rpm -i jump-0.67.0-1.x86_64.rpm |
| Void |
xbps-install -S jump |
Shell Integration
Jump is used through its helper function β j by default. Add it to your shell:
bash / zsh
eval "$(jump shell)"
fish
PowerShell
Invoke-Expression (&jump shell pwsh | Out-String)
Nushell
jump shell nushell | save --append $nu.config-path
Murex
murex-package install https://github.com/lmorg/murex-module-jump.git
Jump begins...