Open ghost opened 2 years ago
Hi, I see the same issue and need to deactivate it every single time. Thanks to @tim78245 for opening up. I agree that moving away from posix to a non-standard-tool is not a good recommendation, especially when all other suggestions try to push you to moving to POSIX standards. ;-)
You can globally disable certain checks.
I know. But I have to do it in every ci script I write. So I still have to do it multiple times, once for each source code repository.
Any update on this?
For bugs
Shellcheck currently recommends to use
pgrep
instead ofps | grep
. That's fine... if one's on a system with pgrep, but pgrep is not POSIX and not everyone has pgrep (for example AIX).See also #2449 in which SC2012 does the same.
I'm not sure what the project's stance is recommending the user away from POSIX. I'm inclined to think it should not, particularly if one is targeting /bin/sh or /bin/ksh, but at the very least the wiki should make a note that the error should be ignored if POSIX compliance is important or if the target system lacks the command/option.