mirror of
https://github.com/koalaman/shellcheck.git
synced 2025-10-03 19:29:44 +08:00
Updated Sc2004 (markdown)
@@ -1,4 +1,4 @@
|
||||
# Don't use $ on variables in (( )).
|
||||
# $/${} is unnecessary on arithmetic variables.
|
||||
|
||||
### Problematic code:
|
||||
|
||||
@@ -12,4 +12,4 @@
|
||||
|
||||
The `$` on regular variables in arithmetic contexts has no purpose, and is just noise.
|
||||
|
||||
The `$` does matter for special variables like `$1` vs `1`, `$#` vs `#`, and ShellCheck does not produce this style suggestion for these cases.
|
||||
The `$` does matter for special variables like `$1` vs `1`, `$#` vs `#`. ShellCheck does not produce this style suggestion for these cases.
|
Reference in New Issue
Block a user