feddit.nl
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
chaoticAnimals@programming.devM to commandline@programming.dev · 3 年前

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

message-square
message-square
24
link
fedilink
15
message-square

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

chaoticAnimals@programming.devM to commandline@programming.dev · 3 年前
message-square
24
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 # to comment.
  • mug9145@chat.maiion.com
    link
    fedilink
    arrow-up
    6
    ·
    3 年前

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

    • chaoticAnimals@programming.devOPM
      link
      fedilink
      arrow-up
      1
      ·
      3 年前

      Interesting :)

  • kisor@programming.dev
    link
    fedilink
    arrow-up
    4
    ·
    3 年前
    • 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
  • 𝕊𝕚𝕤𝕪𝕡𝕙𝕖𝕒𝕟@programming.dev
    link
    fedilink
    English
    arrow-up
    4
    ·
    3 年前

    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
      ·
      3 年前

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

  • FiveAcres@programming.dev
    link
    fedilink
    arrow-up
    4
    ·
    3 年前

    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@lemmy.sdf.org
      link
      fedilink
      arrow-up
      1
      ·
      3 年前

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

  • Gamma@programming.devM
    link
    fedilink
    arrow-up
    3
    ·
    3 年前

    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
    3
    ·
    3 年前

    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
      ·
      3 年前

      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
      1
      ·
      3 年前

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

  • Algae@programming.dev
    link
    fedilink
    English
    arrow-up
    3
    ·
    edit-2
    3 年前

    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
  • RandomDevOpsDude@programming.dev
    link
    fedilink
    arrow-up
    3
    ·
    edit-2
    3 年前

    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

  • mim@lemmy.sdf.org
    link
    fedilink
    arrow-up
    3
    ·
    3 年前

    Taskwarrior.

  • fallenpixel@programming.dev
    link
    fedilink
    arrow-up
    2
    ·
    3 年前

    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
      ·
      3 年前

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

    • RandomDevOpsDude@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      3 年前

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

    • nevalem@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      3 年前

      Don’t forget about fq!

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: [email protected]
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
  • 29 users / month
  • 152 users / 6 months
  • 19 local subscribers
  • 2.15K subscribers
  • 105 Posts
  • 228 Comments
  • Modlog
  • mods:
  • Erlingur@programming.dev
  • chaoticAnimals@programming.dev
  • Spyros@programming.dev
  • Gamma@programming.dev
  • BE: 0.19.15
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org