File tree Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Original file line number Diff line number Diff line change 11# Bash Language Server
22
3+ ## 5.4.3
4+
5+ - Do not overwrite user-provided shellcheck ` --shell ` argument https://github.com/bash-lsp/bash-language-server/pull/1133
6+
37## 5.4.2
48
59- Fix wrong pnpm engine version
Original file line number Diff line number Diff line change 33 "description" : " A language server for Bash" ,
44 "author" : " Mads Hartmann" ,
55 "license" : " MIT" ,
6- "version" : " 5.4.2 " ,
6+ "version" : " 5.4.3 " ,
77 "main" : " ./out/server.js" ,
88 "typings" : " ./out/server.d.ts" ,
99 "bin" : {
Original file line number Diff line number Diff line change @@ -120,13 +120,19 @@ export class Linter {
120120 . map ( ( folderName ) => `--source-path=${ folderName } ` )
121121
122122 const args = [
123- `--shell=${ shellName } ` ,
124123 '--format=json1' ,
125124 '--external-sources' ,
126125 ...sourcePathsArgs ,
127126 ...additionalArgs ,
128127 ]
129128
129+ // only add `--shell` argument if non is provided by the user in their
130+ // config. This allows to the user to override the shell. See #1064.
131+ const userArgs = additionalArgs . join ( ' ' )
132+ if ( ! ( userArgs . includes ( '--shell' ) || userArgs . includes ( '-s ' ) ) ) {
133+ args . unshift ( `--shell=${ shellName } ` )
134+ }
135+
130136 logger . debug ( `ShellCheck: running "${ this . executablePath } ${ args . join ( ' ' ) } "` )
131137
132138 let out = ''
You can’t perform that action at this time.
0 commit comments