File tree Expand file tree Collapse file tree 3 files changed +10
-3
lines changed
Expand file tree Collapse file tree 3 files changed +10
-3
lines changed Original file line number Diff line number Diff line change 25462546 {
25472547 "command" : " review.copyPrLink" ,
25482548 "when" : " github:inReviewMode"
2549+ },
2550+ {
2551+ "command" : " pr.preferredCodingAgentGitHubRemote" ,
2552+ "when" : " false"
25492553 }
25502554 ],
25512555 "view/title" : [
Original file line number Diff line number Diff line change 325325 "command.codingAgent.openSessionLog.title" : " Open Coding Agent Session Log" ,
326326 "command.pr.checkoutChatSessionPullRequest.title" : " Checkout Pull Request" ,
327327 "command.pr.closeChatSessionPullRequest.title" : " Close Pull Request" ,
328- "command.pr.preferredCodingAgentGitHubRemote.title" : " Target GitHub remote for new coding agent sessions " ,
328+ "command.pr.preferredCodingAgentGitHubRemote.title" : " Set Preferred GitHub Remote " ,
329329 "command.pr.resetCodingAgentPreferences.title" : " Reset Coding Agent Workspace Preferences" ,
330330 "command.pr.cancelCodingAgent.title" : " Cancel Coding Agent" ,
331331 "welcome.github.login.contents" : {
Original file line number Diff line number Diff line change @@ -238,7 +238,9 @@ export class CopilotRemoteAgentManager extends Disposable {
238238
239239 const ghRemotes = await fm . getAllGitHubRemotes ( ) ;
240240 Logger . trace ( `There are ${ ghRemotes . length } GitHub remotes available to select from` , CopilotRemoteAgentManager . ID ) ;
241+
241242 if ( ! ghRemotes || ghRemotes . length <= 1 ) {
243+ // Unexpected if we reach here, command should be hidden.
242244 Logger . trace ( 'No need to select a coding agent GitHub remote, skipping prompt' , CopilotRemoteAgentManager . ID ) ;
243245 return ;
244246 }
@@ -247,12 +249,13 @@ export class CopilotRemoteAgentManager extends Disposable {
247249 ghRemotes ,
248250 itemValue => `${ itemValue . remoteName } (${ itemValue . owner } /${ itemValue . repositoryName } )` ,
249251 {
250- title : vscode . l10n . t ( 'Set the GitHub remote to target when creating a coding agent session ' ) ,
252+ title : vscode . l10n . t ( 'Coding agent will create pull requests against the selected remote. ' ) ,
251253 }
252254 ) ;
253255
254256 if ( ! result ) {
255- Logger . warn ( 'No coding agent GitHub remote selected. Clearing preferences.' , CopilotRemoteAgentManager . ID ) ;
257+ Logger . warn ( 'No coding agent GitHub remote selected.' , CopilotRemoteAgentManager . ID ) ;
258+ Logger . warn ( `Keeping previous value of: ${ this . context . workspaceState . get < string > ( PREFERRED_GITHUB_CODING_AGENT_REMOTE_WORKSPACE_KEY ) } ` , CopilotRemoteAgentManager . ID ) ;
256259 return ;
257260 }
258261
You can’t perform that action at this time.
0 commit comments