News for hackers. Stuff that matters.
Re:Argbash: Bash argument parsing code generator by faho on Wednesday March 23, 2022 @08:40AM (#30777816)
GNU grep doesn't take a value for `-E`, so it interprets this as `grep -i -E -t`, which explains the error. It doesn't have a `-t` option.

I don't know of any grep that does take a value for `-E`.

It does support taking a value for `-f`, and it also does support that as the last option in a group:

    grep -qf/path/to/file
works, even if path is something like "patterns" (see that "t" in there?).

>So, once again: what is "correct", when it comes to option handling? Your example was grep, but by the examples of other GNU tools, it only does an "approximation".

I believe you're simply mistaken about what options it takes, and which options take values, the parsing seems "correct".

Re:Argbash: Bash argument parsing code generator by stephenr on Wednesday March 23, 2022 @09:45AM (#30778379)
Welp yep, the folly of -E vs -e (was someone saying one character options are fine?)

You're right that grep does support what I intended to try (`grep -iet`).