File tree Expand file tree Collapse file tree 3 files changed +7
-3
lines changed Expand file tree Collapse file tree 3 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -513,7 +513,7 @@ export class Commands {
513
513
configDir ,
514
514
) ;
515
515
terminal . sendText (
516
- `${ escapeCommandArg ( binary ) } ${ globalFlags . length === 0 ? "" : ` ${ globalFlags . join ( " " ) } ` } ssh ${ app . workspace_name } ` ,
516
+ `${ escapeCommandArg ( binary ) } ${ ` ${ globalFlags . join ( " " ) } ` } ssh ${ app . workspace_name } ` ,
517
517
) ;
518
518
await new Promise ( ( resolve ) => setTimeout ( resolve , 5000 ) ) ;
519
519
terminal . sendText ( app . command ?? "" ) ;
Original file line number Diff line number Diff line change @@ -2,6 +2,10 @@ import { WorkspaceConfiguration } from "vscode";
2
2
import { getHeaderArgs } from "./headers" ;
3
3
import { escapeCommandArg } from "./util" ;
4
4
5
+ /**
6
+ * Returns global configuration flags for Coder CLI commands.
7
+ * Always includes the `--global-config` argument with the specified config directory.
8
+ */
5
9
export function getGlobalFlags (
6
10
configs : WorkspaceConfiguration ,
7
11
configDir : string ,
Original file line number Diff line number Diff line change @@ -826,11 +826,11 @@ export class Remote {
826
826
827
827
private globalConfigs ( label : string ) : string {
828
828
const vscodeConfig = vscode . workspace . getConfiguration ( ) ;
829
- const args : string [ ] = getGlobalFlags (
829
+ const args = getGlobalFlags (
830
830
vscodeConfig ,
831
831
path . dirname ( this . storage . getSessionTokenPath ( label ) ) ,
832
832
) ;
833
- return args . length === 0 ? "" : ` ${ args . join ( " " ) } ` ;
833
+ return ` ${ args . join ( " " ) } ` ;
834
834
}
835
835
836
836
// showNetworkUpdates finds the SSH process ID that is being used by this
You can’t perform that action at this time.
0 commit comments