@@ -12,49 +12,66 @@ import { Equals, Keys, AssertEqual } from "../utils/type-fu"
1212
1313import { publisher , name , version } from "../../package.json"
1414
15+ // These ENV variables can be defined by ESBuild when building the extension
16+ // in order to override the values in package.json. This allows us to build
17+ // different extension variants with the same package.json file.
18+ // The build process still needs to emit a modified package.json for consumption
19+ // by VSCode, but that build artifact is not used during the transpile step of
20+ // the build, so we still need this override mechanism.
1521export const Package = {
16- publisher,
17- name,
18- version,
22+ publisher : process . env . PKG_PUBLISHER || publisher ,
23+ name : process . env . PKG_NAME || name ,
24+ version : process . env . PKG_VERSION || version ,
25+ outputChannel : process . env . PKG_OUTPUT_CHANNEL || "Roo-Code" ,
1926} as const
2027
2128/**
2229 * CodeAction
2330 */
2431
25- export type CodeActionName = "EXPLAIN" | "FIX" | "IMPROVE" | "ADD_TO_CONTEXT" | "NEW_TASK"
32+ export const codeActionIds = [ "explainCode" , "fixCode" , "improveCode" , "addToContext" , "newTask" ] as const
33+
34+ export type CodeActionId = ( typeof codeActionIds ) [ number ]
2635
27- export type CodeActionId = "explainCode " | "fixCode " | "improveCode " | "addToContext " | "newTask "
36+ export type CodeActionName = "EXPLAIN " | "FIX " | "IMPROVE " | "ADD_TO_CONTEXT " | "NEW_TASK "
2837
2938/**
3039 * TerminalAction
3140 */
3241
42+ export const terminalActionIds = [ "terminalAddToContext" , "terminalFixCommand" , "terminalExplainCommand" ] as const
43+
44+ export type TerminalActionId = ( typeof terminalActionIds ) [ number ]
45+
3346export type TerminalActionName = "ADD_TO_CONTEXT" | "FIX" | "EXPLAIN"
3447
3548export type TerminalActionPromptType = `TERMINAL_${TerminalActionName } `
3649
37- export type TerminalActionId = "terminalAddToContext" | "terminalFixCommand" | "terminalExplainCommand"
38-
3950/**
4051 * Command
4152 */
4253
43- const commandIds = [
54+ export const commandIds = [
4455 "activationCompleted" ,
56+
4557 "plusButtonClicked" ,
46- "mcpButtonClicked" ,
4758 "promptsButtonClicked" ,
59+ "mcpButtonClicked" ,
60+ "historyButtonClicked" ,
4861 "popoutButtonClicked" ,
49- "openInNewTab" ,
5062 "settingsButtonClicked" ,
51- "historyButtonClicked" ,
63+
64+ "openInNewTab" ,
65+
5266 "showHumanRelayDialog" ,
5367 "registerHumanRelayCallback" ,
5468 "unregisterHumanRelayCallback" ,
5569 "handleHumanRelayResponse" ,
70+
5671 "newTask" ,
72+
5773 "setCustomStoragePath" ,
74+
5875 "focusInput" ,
5976 "acceptInput" ,
6077] as const
0 commit comments