mirror of
https://github.com/koalaman/shellcheck
synced 2025-07-30 11:39:20 -07:00
Warn about while read f; do ssh "$f"; done
This commit is contained in:
parent
d4bc0f6e10
commit
a4d36ba0d2
2 changed files with 37 additions and 1 deletions
|
@ -308,7 +308,7 @@ readConditionContents single = do
|
|||
id <- getNextId
|
||||
x <- try (string "||" <|> string "-o")
|
||||
when (single && x == "||") $ addNoteFor id $ Note ErrorC 1024 "You can't use || inside [..]. Use [[..]] instead."
|
||||
when (not single && x == "-o") $ addNoteFor id $ Note ErrorC 1025 "In [[..]], use && instead of -o."
|
||||
when (not single && x == "-o") $ addNoteFor id $ Note ErrorC 1025 "In [[..]], use || instead of -o."
|
||||
softCondSpacing
|
||||
return $ TC_Or id typ x
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue