File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed
Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -91,6 +91,7 @@ commandChecks = [
9191 ,checkMvArguments, checkCpArguments, checkLnArguments
9292 ,checkFindRedirections
9393 ,checkReadExpansions
94+ ,checkWhich
9495 ]
9596
9697buildCommandMap :: [CommandCheck ] -> Map. Map CommandName (Token -> Analysis )
@@ -939,6 +940,9 @@ checkFindRedirections = CommandCheck (Basename "find") f
939940 " Redirection applies to the find command itself. Rewrite to work per action (or move to end)."
940941 _ -> return ()
941942
943+ prop_checkWhich = verify checkWhich " which '.+'"
944+ checkWhich = CommandCheck (Basename " which" ) $
945+ \ t -> info (getId t) 2230 " which is non-standard. Use builtin 'command -v' instead."
942946
943947return []
944948runTests = $ ( [| $ (forAllProperties) (quickCheckWithResult (stdArgs { maxSuccess = 1 }) ) | ])
You can’t perform that action at this time.
0 commit comments