Ask HN: Are there enough utilities in bash now?

I'm curious to know if bash is completely filling all the boxes and everything is perfect, or would it be great to have some more utilities? Share your thoughts.

3 points

Forgret

4 days ago


12 comments

asen_not_taken 3 days ago

I don't really use bash anymore for anything complex. The cognitive load of remembering all the commands and options is just too high. I simply describe what I need to do to claude code, and it gives me the exact one-liner I need. For me, that's the ultimate "utility" we've been looking for.

slightwinder 3 days ago

I don't understand the question. There is no perfection in software.

And what does "utilities in bash" mean? Do you mean features of specifically the bash-shell? Do you mean shell-tools in general? Or shells in general?

  • Forgret 3 days ago

    Utilities: ls, cp, grep etc. That is, are they all ideally suited for their purpose or do they have any drawbacks, and are there enough of them Bash Should there be more of them?

    • slightwinder 3 days ago

      > Utilities: ls, cp, grep etc.

      These are unrelated to bash. They are just commandline-tools; you can call them from any shell.

      > do they have any drawbacks,

      They all have their drawbacks, which is why there are constantly new tools, improving that space.

    • sksrbWgbfK 2 days ago

      > more of them

      More of what? What do you need and what are your problems?

bjourne 3 days ago

If you're talking about bash the shell scripting language then yes. In fact, I assert that removing dumb "features" is the only way to make it better.

stop50 4 days ago

I use shell for simple things like "do this for all the files in here". shellscripts for repeated stuff and wgeb it gets complicated i turn to programming languages like python

  • Forgret 4 days ago

    So, is the standard set of Bash syntax completely enough for you?

    • sksrbWgbfK 2 days ago

      The bash syntax is irrelevant to the tools available. It's useless without tools to run.

cpach 4 days ago

Handling of maps/dictionaries could probably be improved. The current solution feels quite clunky.

no_time 3 days ago

Not really a utility per se, but I really really wish that echo {1..n} would run echo n number of times with the current index as the argument instead of expanding to a single string that gets printed.

I know you can do a for loop as a one liner but I somehow never get it right the first time and turns out to be a bit of a PIA.

  • Forgret 3 days ago

    You can use the following command:

    for i in {1..5}; do echo $i; done