4 ms·
I usually do this by hand. Good to see a tool for it :-) Feature request, which I would love to have in all my automation scripts: Replace short flags with th
by kmarc 2y ago
I usually do this by hand. Good to see a tool for it :-)
Feature request, which I would love to have in all my automation scripts:
Replace short flags with the long switches. Short flags are great when typing in a terminal but I don't want to figure out 2 years from now what the
obscurecommand -v -f -n
does, and I have to assume that it's NOT --version --file --dry-run, but --verbose, --force, and --dont-ask-before-deleting-everything
I try to use long options in my script, therefore (especially in a team, where not everyone is familiar with every single command)
- notpushkin 2y agoIt would be a great rule for shellcheck, by the way. Line 6: curl -fsSL "${url}" ^-- SC8537 (warning): use long options instead (`--fail`, `--silent`, `--show-error`, `--location`).
- yjftsjthsd-h 2y agoI would want it opt-in, because I use shellcheck on scripts that will be run on busybox or *BSD where there aren't long options
- notpushkin 2y agoOf course.
- yjftsjthsd-h 2y agoOh, I didn't realize shellcheck already had optional checks (see `shellcheck --list-optional` for a list), so that was not obvious to me initially. Then yes, that'd be a good thing to have available.
- jakub_g 2y agoWhen I saw "deminifier for shell commands" in title I had exactly the same in mind.