If there is perhaps just _one_ thing that we can all admit that LLM's are good at, it should be bash one-liners for common tasks.
Which is to say, I highly recommend using an LLM for exploring commands to run in a terminal. Once past the learning curve, it is a good way to avoid dozens to hundreds of cryptic short-options (just ask for only long options).
> If there is perhaps just _one_ thing that we can all admit that LLM's are good at, it should be bash one-liners for common tasks.
Sorry to disappoint, but no can do on that agreement. The web is full of bad advice for shell scripting one liners, because too many people fumble their way to a semi-workable inefficient solution for their specific problem, then instead of attempting to refine it and make it better by removing extraneous options they publish it as is to a blog post or gist. The result is that LLMs ingest a lot of subpar commands.
I’ve tested this many times. It is rare that an LLM returns me a one-liner that I can’t immediately see how to improve.
The interesting thing is that there are objective measurements about code (like unnecessary commands in answers, or code which flat out never worked), in which generally people are not great. The amount of bad answers on Stackoverflow and on most of the blogspam is staggering. Even reference documentations are bad or wrong many times. LLMs work with that. They won’t be better than that.
Which is to say, I highly recommend using an LLM for exploring commands to run in a terminal. Once past the learning curve, it is a good way to avoid dozens to hundreds of cryptic short-options (just ask for only long options).