Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9d80d67

Browse files
fix: handle agent parameter in URIs (#538)
This fixes a bug where the `agent` query parameter on the extension URI was ignored.We were previously doing:```tsvscode.commands.executeCommand("coder.openDevContainer",workspaceOwner,workspaceName,workspaceAgent,devContainerName,devContainerFolder,);```where `args[2]` was the agent name, but we were discarding it:```tsconst workspaceOwner = args[0] as string;const workspaceName = args[1] as string;const workspaceAgent = undefined; // args[2] is reserved, but we do not support multiple agents yet.const devContainerName = args[3] as string;const devContainerFolder = args[4] as string;```The same was true for the `coder.open` command. Presumably due to the comment saying multiple agents aren't supported, which hasn't been true for years.
1 parentd1289c6 commit9d80d67

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

‎.git-blame-ignore-revs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# If you would like `git blame` to ignore commits from this file, run:
2+
# git config blame.ignoreRevsFile .git-blame-ignore-revs
3+
4+
# chore: simplify prettier config (#528)
5+
f785902f3ad20d54344cc1107285c2a66299c7f6

‎src/commands.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -600,7 +600,7 @@ export class Commands {
600600
}else{
601601
workspaceOwner=args[0]asstring;
602602
workspaceName=args[1]asstring;
603-
//workspaceAgentis reserved forargs[2], but multiple agents aren't supported yet.
603+
workspaceAgent=args[2]asstring|undefined;
604604
folderPath=args[3]asstring|undefined;
605605
openRecent=args[4]asboolean|undefined;
606606
}
@@ -628,7 +628,7 @@ export class Commands {
628628

629629
constworkspaceOwner=args[0]asstring;
630630
constworkspaceName=args[1]asstring;
631-
constworkspaceAgent=undefined;//args[2]is reserved, but we do not support multiple agents yet.
631+
constworkspaceAgent=args[2]asstring;
632632
constdevContainerName=args[3]asstring;
633633
constdevContainerFolder=args[4]asstring;
634634

@@ -748,7 +748,7 @@ async function openDevContainer(
748748
baseUrl:string,
749749
workspaceOwner:string,
750750
workspaceName:string,
751-
workspaceAgent:string|undefined,
751+
workspaceAgent:string,
752752
devContainerName:string,
753753
devContainerFolder:string,
754754
){

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp