Skip to content

Nice to Know

Herafter a list of handy nict to know CLI tools. Many of them are written in rust.

Check out also Rust Utils

Tool Replaces Type Example Description
starhip - Cross-Shell Prompt - Customizable shell prompt for any shell
procs ps Process Viewer procs -a List all processes with a concise and readable format
atuin - Shell history - Sync, search and backup shell history
hyperfine - Benchmark hyperfine 'cargo build' Measure the execution time of 'cargo build' command
duf du Disk Usage duf -s Display disk usage with a simple and interactive interface
dust du Disk Usage dust -n 10 Visualize disk usage of the current directory
diskonaut dust Disk Space Navigator diskonaut Visualize disk usage of the current directory
broot cd ls Navigate Directories br A new way to see and navigate directory trees
exa ls Listing exa -l -G List files with extended details and colored output
ripgrep grep Search rg -i TODO src/ --glob "*.md" Recursively searches directories within markdown files for a regex pattern
sd sed Search and Replace sd before after file.txt Painless seardh and replace with regex
bat cat Pager bat src/main.rs View files with syntax highlighting and Git integration
btop top Resource viewer zenith Zenith - sort of like top or htop but with zoom-able charts, network, and disk usage.
zenith top Resource viewer zenith Zenith - sort of like top or htop but with zoom-able charts, network, and disk usage.
delta diff Visual Diff git diff | delta Enhance the git diff output with improved layout and styling
tokei - Code Statistics tokei src/ Generate code statistics for the Rust source directory
shellcheck - Shell Script Linter shellcheck myscript.bash Finds bugs in your shell scripts
numbat - Scientific Calculator numbat A statically typed programming language for scientific computations with first class support for physical dimensions and units
tealdear man tldr tldr hyperfine Communicty driven man pages
thefuck - CLI Corrector f corrects automagially your previous console command

Finder tools

Tool Replaces Type Example Description
fd find Search fd '*.rs' Find files, user-friendlier than find
fzf - Fuzzy Finder fzf Fuzzy Finder, integrated with commands for interactive file selection
skim fzf Fuzzy Finder sk Fuzzy Finder, integrated with commands for interactive file selection
tv fzf sk Fuzzy Finder tv Fuzzy Finder, with tui allow finding env vars, files, file content, git repos, alias

Multimedia tools

Tool Replaces Type Example Description
codesnap - Code Images codesnap -c "echo 'Hello, World!'" -o clipboard --title "Hello, World!"s Created images of code via a terminal CLI
t-rec - Terminal Recording t-rec -o session.gif A tool to record your terminal sessions as animated GIFs
asciinema - Terminal Recording asciinema rec Record and share terminal sessions, with playback options (web or terminal)

CodeSnap Configuration

~/.config/CodeSnap/config.json
{
  "window": {
    "mac_window_bar": true,
    "shadow": 10,
    "margin": {
      "x": 20,
      "y": 40
    }
  },
  "code": {
    "font_family": "CaskaydiaCove Nerd Font",
    "theme": "candy"
  },
  "watermark": {
    "content": "",
    "font_family": "Pacifico",
    "color": "#ffffff"
  },
  "background": {
    "start": {
      "x": 0,
      "y": 0
    },
    "end": {
      "x": 0,
      "y": 0
    },
    "stops": [
      {
        "position": 0,
        "color": "#ffffff"
      }
    ]
  }
}

Commonly used commands

skim in interactive mode with preview script and bind Ctrl-Y to copy filename and F4 open in Sublime Text

sk --ansi -i -c 'ag --color "{}"' --preview "./preview.sh {}" --bind 'f3:execute(subl -f {}),ctrl-y:execute-silent(echo {} | pbcopy)+abort'
exa -la