Christian Nassif-Haynes
581981ba76
Suppress SC2311 with `set -o posix`
2022-09-24 07:20:48 +10:00
Vidar Holen
5cf6e01ce9
Warn when $? refers to echo or condition (ref #2541 )
2022-07-23 09:39:26 -07:00
Vidar Holen
f77a545282
Control Flow Graph / Data Flow Analysis support
2022-07-20 08:08:24 -07:00
Vidar Holen
dd626686c4
Merge pull request #2375 from scop/spelling
...
Comment spelling fixes
2021-12-05 14:27:08 -08:00
Vidar Holen
d9a9d5db86
Mark prefix/postfix inc/dec as integers ( fixes #2376 )
2021-11-14 16:39:32 -08:00
Ville Skyttä
c5de58ae84
Comment spelling fixes
2021-11-13 12:50:53 +02:00
Vidar Holen
3b6972fbf1
Update copyright years
2021-11-06 19:07:34 -07:00
Vidar Holen
788aee1b7c
Treat typeset similar to declare ( fixes #2354 )
2021-10-15 14:41:48 -07:00
Vidar Holen
c3aaa27540
Skip SC2214 if variable is modified in loop ( fixes #2351 )
2021-10-09 12:13:41 -07:00
Christian Nassif-Haynes
093df8cb24
Add extra checks for masked return codes
2021-10-02 01:36:40 +10:00
Vidar Holen
64733cc110
Merge pull request #2303 from DoxasticFox/set-e-functions
...
Show info about `set -e` suppression during function calls
2021-09-04 17:06:24 -04:00
Christian Nassif-Haynes
dc9032fca5
Show info about `set -e` suppression during function calls
2021-09-05 04:23:25 +10:00
Vidar Holen
081f7eba24
Fix parsing of [$var] ( fixes #2309 )
2021-08-26 23:05:14 -07:00
Vidar Holen
5b6fd60279
Improve warnings for expr ( fixes #2033 )
2021-08-22 21:12:58 -07:00
Vidar Holen
da7b28213e
Recognize wait -p as assigning a variable ( fixes #2179 )
2021-08-17 21:53:27 -07:00
Vidar Holen
bb0a571a1e
Improve warnings for bad parameter expansion ( fixes #2297 )
2021-08-16 21:02:20 -07:00
Vidar Holen
cf8066c07c
SC2295 Warn about unquoted variables in PE patterns ( fixes #2290 )
2021-08-03 13:02:53 -07:00
Vidar Holen
a44f3edb14
Warn about eval'ing arrays
2021-07-30 18:46:19 -07:00
Vidar Holen
fe81dc1c27
Optionally suggest [[ over [ in Bash scripts (-o require-double-brackets) ( fixes #887 )
2021-07-27 18:53:30 -07:00
Vidar Holen
02e07625d1
Warn about quoting in assignments to sh declaration utilities ( fixes #1556 )
2021-07-25 19:36:42 -07:00
Vidar Holen
0d58337cdd
Don't warn about repeated range in [[ -v arr[xxx] ]] ( fixes #2285 )
2021-07-25 13:01:57 -07:00
Vidar Holen
163b2f12e2
Sanity check command names ( fixes #2227 )
2021-06-05 18:16:22 -07:00
Vidar Holen
f02c297fdd
Merge parser and analyzer shebang parsing
2021-03-11 23:04:17 -08:00
Vidar Holen
15ff87cf80
Merge pull request #2119 from josephcsible/refactors
...
Various refactorings
2021-02-02 18:14:27 -08:00
Vidar Holen
5fbaae2bb3
Don't treat ${!x@} as reference of x ( fixes #2116 )
2020-12-30 20:55:18 -08:00
Joseph C. Sible
81e84c2939
Use execState instead of snd . runState
2020-12-28 18:13:34 -05:00
Joseph C. Sible
46f177b5be
Simplify parseArgs
2020-12-28 17:19:08 -05:00
Joseph C. Sible
35033a9f2f
Remove unnecessary use of Maybe from shellFor
2020-12-28 17:09:50 -05:00
Vidar Holen
bd3299edd3
Treat 'exec $1' like '$1' for the purpose of quoting ( fixes #2068 )
2020-12-17 20:31:45 -08:00
Vidar Holen
cc3884cf9f
Support env -S/--split-string in shebangs ( fixes #2105 )
2020-12-12 20:24:32 -08:00
Vidar Holen
256457c47a
Use getopts parser to find 'read' arrays ( fixes #2073 )
2020-10-18 22:57:16 -07:00
Vidar Holen
f100c2939e
Rewrite getopts style option parser
2020-10-18 21:34:58 -07:00
Vidar Holen
8d99926554
Recognize `local -x` similarly to `export` ( fixes #2069 )
2020-10-18 15:15:31 -07:00
Vidar Holen
50067ddf94
Consider variables in -z/-n tests to be checked
2020-08-08 12:32:20 -07:00
Vidar Holen
3fa5b7d3bd
Merge branch 'supportMinusNZ' of https://github.com/donnerpeter/shellcheck into donnerpeter-supportMinusNZ
2020-08-08 11:22:00 -07:00
Vidar Holen
e779aedac3
Modernize getting mapfile array name
2020-08-07 16:41:18 -07:00
Vidar Holen
3ef1175566
Merge branch 'issue_1759_mapfile_proc_substition' of https://github.com/Gandalf-/shellcheck into Gandalf--issue_1759_mapfile_proc_substition
2020-08-07 15:57:59 -07:00
Vidar Holen
1ac2c31728
Warn when shell functions blatantly recurse ( fixes #1994 )
2020-07-27 21:50:33 -07:00
Vidar Holen
5d753212fb
Improve handling of command prefixes like exec/command ( fixes #2008 )
2020-07-25 13:45:05 -07:00
Joseph C. Sible
999b7e2596
Get rid of bracedString everywhere it's easy to
2020-04-11 19:24:11 -04:00
Vidar Holen
1eac0d7340
Merge pull request #1900 from josephcsible/analyzerlib
...
Clean up AnalyzerLib
2020-04-11 16:21:20 -07:00
Joseph C. Sible
d22e0aa4a7
Simplify process
...
Note to self: This is a lot like foldr or traverse, and would be trivial to
implement as such if it didn't need to peek ahead when takesArg is true. I
wonder if there's a clean way to implement it in terms of one of them anyway.
2020-04-05 16:45:45 -04:00
Joseph C. Sible
fb55072302
Implement supportsArrays with pattern-matching
2020-04-05 16:30:59 -04:00
Joseph C. Sible
0cc5ed4563
Don't bother with asks if you're just immediately binding the result anyway
2020-04-05 16:25:43 -04:00
Joseph C. Sible
ca41440a67
Simplify getSpecial
2020-04-05 16:21:07 -04:00
Joseph C. Sible
1cf0aa25e9
Simplify dropPrefix
2020-04-05 16:19:18 -04:00
Joseph C. Sible
4604066c37
Use head instead of (!! 0)
2020-04-05 16:16:12 -04:00
Joseph C. Sible
2ebf522a52
Simplify isArrayFlag
2020-04-05 16:13:55 -04:00
Joseph C. Sible
e4eb2d157f
Remove an unnecessary operator section
2020-04-05 16:13:55 -04:00
Joseph C. Sible
f109f9ab92
Remove unnecessary as-patterns
2020-04-05 16:13:55 -04:00