SDF Chatter
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
chaoticAnimals@programming.devM to commandline@programming.dev · 2 years ago

Let's make a list of our favorite CLI utilities.

message-square
message-square
21
link
fedilink
13
message-square

Let's make a list of our favorite CLI utilities.

chaoticAnimals@programming.devM to commandline@programming.dev · 2 years ago
message-square
21
link
fedilink

Any extra tips or tricks are welcome!

Yesterday I learned that set -x enables trace for a bash, sh, or zsh script and prints the trace to the terminal.

alert-triangle
You must log in or register to comment.
  • mug9145@chat.maiion.com
    link
    fedilink
    arrow-up
    6
    ·
    2 years ago

    Newsboat, an RSS reader https://newsboat.org/

    • chaoticAnimals@programming.devOPM
      link
      fedilink
      arrow-up
      1
      ·
      2 years ago

      Interesting :)

  • kisor@programming.dev
    link
    fedilink
    arrow-up
    4
    ·
    2 years ago
    • scoop - closest to apt on Windows
    • yt-dlp - active fork of youtube-dl
    • neofetch - System information display
    • winfetch - Same as neofetch, but for windows
    • pandoc - Ultimate converter
    • ffmpeg - must have tool
    • taskwarrior - best task manager imho
  • FiveAcres@programming.dev
    link
    fedilink
    arrow-up
    4
    ·
    2 years ago

    In Bash, I like to use cdargs

    sudo apt-get install cdargs

    It allows you to set up shortcuts on the fly,

    cv sdbackup

    rather than cd /media/user/Backup Plus/ MyFiles/current/sdbackup

    cv with no argument will give you a list to select from current shortcuts

    • umbraklat
      link
      fedilink
      arrow-up
      1
      ·
      2 years ago

      Of those mentioned, this one intrigues me most. Thanks!

  • mim
    link
    fedilink
    arrow-up
    4
    ·
    2 years ago

    Taskwarrior.

  • 𝕊𝕚𝕤𝕪𝕡𝕙𝕖𝕒𝕟@programming.dev
    link
    fedilink
    English
    arrow-up
    3
    ·
    2 years ago

    I really like jless. You can pipe the JSON output of a cURL command into it and it displays it in a really nice, easy to read way with collapsible arrays and objects.

    • sirnak@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 years ago

      Why haven’t I heard of this before?? Absolute gamechanger o_O

  • fallenpixel@programming.dev
    link
    fedilink
    arrow-up
    3
    ·
    2 years ago

    Always partial to yq and jq. No easier way to interact with kubernetes outputs on the fly.

    • Andy@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      2 years ago

      I don’t know about k8s work in particular, but I enjoy jello and yamlpath more than jq and yq.

    • nevalem@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      2 years ago

      Don’t forget about fq!

    • RandomDevOpsDude@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      2 years ago

      How I have never heard of yq, I’m unsure, but thank you as I’m sure it will make life easier

  • Gamma@programming.devM
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    2 years ago

    pv, which is like cat, simply copying files or stdin to stdout, but prints statistics to the terminal.

    A related tip: dd isn’t special in the way most people use it. This works too, if you’re root: pv my-fav-distro.iso > /dev/sdc

  • chaoticAnimals@programming.devOPM
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    2 years ago

    I’m a pretty big fan of icdiff. This utility allows you to compare two files to see what has been added or removed by using colorful fonts to highlight values.

    https://github.com/jeffkaufman/icdiff

    • Andy@programming.dev
      link
      fedilink
      arrow-up
      3
      ·
      edit-2
      2 years ago

      Another good one is riff (riffdiff on crates.io).

      EDIT: for single-column view, that is

    • cd_slash_rmrf@programming.dev
      link
      fedilink
      arrow-up
      0
      ·
      2 years ago

      I recently learned about diffsitter which uses tree-sitter for meaningful diffs

  • RandomDevOpsDude@programming.dev
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    2 years ago

    I write a lot of bash scripts that end up running in automation in some fashion.

    #!/usr/bin/env bash
    
    set -euxo pipefail
    

    Is pretty standard for me.

    -e exit on error

    -o pipefail exit on pipeline fail

    -u error on unset variables

    -x trace

  • Algae@programming.dev
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    2 years ago

    My answers (mostly running in powershell - not that it makes much of a difference!)

    Rust-based utilities I couldn’t live without:

    • fd (fd-find) for finding my files
    • rg (ripgrep) for string searches
    • sd (sed) for search and replace
    • dust (dust) for information about my directories
    • lsd (aliased to ls or l) for replacing Dir
    • bat (better cat) - for when the help pages are too long

    Other stuff I love:

    • htop - I just learned you can run this in WSL to see all your system cores. It’s pretty!
    • nvim - obviously. The best vim. Even works in VSCode

commandline@programming.dev

commandline@programming.dev

Subscribe from Remote Instance

Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: !commandline@programming.dev
Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 1 user / day
  • 1 user / week
  • 12 users / month
  • 158 users / 6 months
  • 47 local subscribers
  • 2.03K subscribers
  • 97 Posts
  • 228 Comments
  • Modlog
  • mods:
  • Erlingur@programming.dev
  • chaoticAnimals@programming.dev
  • Spyros@programming.dev
  • Gamma@programming.dev
  • BE: 0.19.11
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org