Why CLI tools then? 🛠 Process safety Expert mode Issue: Outdated distribution packages Do one thing and do it well!
Slide 6
Modern CLI tools? Many tools still stem from the early UNIX times Rise of the developer UTF8 Colors
🏎 Faster terminals Debugging (ephemeral containers, no local logs, remote)
Slide 7
New languages Rust Go Crystal JVM: GraalVM, Kotlin Native, Scala Native Zig V
Slide 8
New languages Binary as a result, best startup time No C/memory management learning required Faster development
Slide 9
Shell - zsh in combination with oh-my-zsh scripting syntax similar to bash lots of plugins for easier development
Slide 10
Shell - alternatives bash fish nushell
Slide 11
Slide 12
Shell Prompt - GBT
Slide 13
Shell Prompt - GBT
Slide 14
Shell Prompt - Starship
Slide 15
Shell aliases Make sure you alias what you type often! .. ll
Slide 16
wd
Slide 17
Shell history search Ctrl+R triggers history search Extremely powerful Ensure your history gets written after command execution instead of logout
Slide 18
lsd
Slide 19
lsd a better ls colored output relative/absolute timestamps file type icons (nerdfonts) tree view total directory size view
Slide 20
bat
Slide 21
bat cat with wings Syntax highlighting & themes Line highlighting Range snippets (no more cat | head | tail parties) git integration builtin pagination
Slide 22
fd
Slide 23
fd a better find, very similar syntax colors! takes .gitignore into account case-insensitive by default regexes parallel command execution (when used with -x )
Slide 24
ripgrep
Slide 25
ripgrep It’s fast! match patterns across newlines takes .gitignore into account skips dot files and binary files recursive && regexing by default replacement of matched text ripgrep-all to search in binary files
version managers JVM: sdkman nodejs: nvm ruby: rvm Problem: per project requirements
Slide 39
direnv - unclutter your profile .envrc layout node export NODE_VERSIONS=~/.nvm/versions/node export NODE_VERSION_PREFIX=’v’ use node 15.11.0 dotenv
Slide 40
direnv - unclutter your profile .env DB_USERNAME=”sa” DB_PASSWORD=”” DB_URL=”jdbc:h2:mem:foo_in_memory;MODE=PostgreSQL;DB_CLOSE_DELAY=-1;DATABASE_TO_UPPER=false”
Run direnv allow after a change
Slide 41
envchain - store secrets securely
envchain —set my_app DB_PASSWORD envchain ./gradlew run
Slide 42
Better diffs
Slide 43
colordiff
Slide 44
icdiff
Slide 45
scc - source code analyzer
Slide 46
Honorable mentions GPU based terminal emulators: alacritty & kitty exiftool, remove exif data exiftool -all= my.png tmux - next session will be all about tmux! sd, a faster sed alternative zoxide, a new cd that remembers your most common paths
Slide 47
Honorable mentions rlwrap, a readline wrapper cli, the github cli tool taskwarrior, the CLI todo management tool
Slide 48
Missing Note taking tool, that automatically syncs in the cloud/via git Time tracking? What are your favourite tools? Feel free to ping (twitter, email, linkedin, whatever)
Slide 49
Write CLI tools
Command Line Interface Guidelines
Slide 50
Resources direnv envchain fish shell Starship fd bat hyperfine
Slide 51
Resources ripgrep ripgrep-all Grep tools feature comparison Rewritten in Rust: Modern Alternatives of Command-Line Tools Command Line Interface Guidelines A better zsh history
Slide 52
Thanks for listening Q&A Alexander Reelsen alex@elastic.co | @spinscale