mirror of
https://github.com/koalaman/shellcheck
synced 2025-08-14 02:27:30 -07:00
Fixed quoted ~ warning to only trigger for ~/
This commit is contained in:
parent
dcc10bbdf6
commit
0a2cf208c8
2 changed files with 2 additions and 2 deletions
|
@ -1852,7 +1852,7 @@ prop_checkTildeInQuotes5 = verifyNot checkTildeInQuotes "echo '/~foo/cow'"
|
|||
prop_checkTildeInQuotes6 = verifyNot checkTildeInQuotes "awk '$0 ~ /foo/'"
|
||||
checkTildeInQuotes _ = check
|
||||
where
|
||||
verify id ('~':_) = warn id 2088 "Note that ~ does not expand in quotes."
|
||||
verify id ('~':'/':_) = warn id 2088 "Note that ~ does not expand in quotes."
|
||||
verify _ _ = return ()
|
||||
check (T_NormalWord _ (T_SingleQuoted id str:_)) =
|
||||
verify id str
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue