mirror of
https://github.com/koalaman/shellcheck.git
synced 2025-08-08 14:27:35 +08:00
Clarify 'export' suggestion in SC2034 (unused vars).
This commit is contained in:
@@ -1817,7 +1817,7 @@ checkUnusedAssignments params t = execWriter (mapM_ warnFor unused)
|
|||||||
|
|
||||||
warnFor (name, token) =
|
warnFor (name, token) =
|
||||||
warn (getId token) 2034 $
|
warn (getId token) 2034 $
|
||||||
name ++ " appears unused. Verify it or export it."
|
name ++ " appears unused. Verify use (or export if used externally)."
|
||||||
|
|
||||||
stripSuffix = takeWhile isVariableChar
|
stripSuffix = takeWhile isVariableChar
|
||||||
defaultMap = Map.fromList $ zip internalVariables $ repeat ()
|
defaultMap = Map.fromList $ zip internalVariables $ repeat ()
|
||||||
|
Reference in New Issue
Block a user