@kaitranntt/ccs 7.58.0-dev.2 → 7.58.0-dev.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cliproxy/config/extended-context-config.d.ts.map +1 -1
- package/dist/cliproxy/config/extended-context-config.js +5 -45
- package/dist/cliproxy/config/extended-context-config.js.map +1 -1
- package/dist/cliproxy/model-id-normalizer.d.ts.map +1 -1
- package/dist/cliproxy/model-id-normalizer.js +2 -6
- package/dist/cliproxy/model-id-normalizer.js.map +1 -1
- package/dist/commands/api-command/create-command.d.ts.map +1 -1
- package/dist/commands/api-command/create-command.js +51 -7
- package/dist/commands/api-command/create-command.js.map +1 -1
- package/dist/commands/api-command/help.d.ts +3 -1
- package/dist/commands/api-command/help.d.ts.map +1 -1
- package/dist/commands/api-command/help.js +77 -70
- package/dist/commands/api-command/help.js.map +1 -1
- package/dist/commands/api-command/index.d.ts +15 -0
- package/dist/commands/api-command/index.d.ts.map +1 -1
- package/dist/commands/api-command/index.js +41 -17
- package/dist/commands/api-command/index.js.map +1 -1
- package/dist/commands/api-command/shared.d.ts +6 -1
- package/dist/commands/api-command/shared.d.ts.map +1 -1
- package/dist/commands/api-command/shared.js +38 -2
- package/dist/commands/api-command/shared.js.map +1 -1
- package/dist/commands/help-command.d.ts +3 -1
- package/dist/commands/help-command.d.ts.map +1 -1
- package/dist/commands/help-command.js +88 -81
- package/dist/commands/help-command.js.map +1 -1
- package/dist/shared/extended-context-utils.d.ts +19 -0
- package/dist/shared/extended-context-utils.d.ts.map +1 -1
- package/dist/shared/extended-context-utils.js +56 -1
- package/dist/shared/extended-context-utils.js.map +1 -1
- package/dist/ui/assets/{accounts-CYJwzq9g.js → accounts-By8RF3Hf.js} +1 -1
- package/dist/ui/assets/{alert-dialog-B8EI9gra.js → alert-dialog-but7uZOd.js} +1 -1
- package/dist/ui/assets/{api-DxUnme4s.js → api-BXyHGgwH.js} +1 -1
- package/dist/ui/assets/{auth-section-D7PsPGEM.js → auth-section-BvlV5Svq.js} +1 -1
- package/dist/ui/assets/{backups-section-Cm3lyE9d.js → backups-section-CGaIc7JG.js} +1 -1
- package/dist/ui/assets/{channels-H6YmNNxH.js → channels-Bi_lqY4h.js} +1 -1
- package/dist/ui/assets/{checkbox-DYYN1zJe.js → checkbox-DvIiddjE.js} +1 -1
- package/dist/ui/assets/{claude-extension-Ct-Dcf-x.js → claude-extension-BV8MUy8f.js} +1 -1
- package/dist/ui/assets/cliproxy-C_CkCEoF.js +3 -0
- package/dist/ui/assets/{cliproxy-ai-providers-Bq3gW2E-.js → cliproxy-ai-providers-DJGuVuo3.js} +1 -1
- package/dist/ui/assets/{cliproxy-control-panel-CzFcUx6s.js → cliproxy-control-panel-DHP7TjOS.js} +1 -1
- package/dist/ui/assets/{confirm-dialog-DalRN9Os.js → confirm-dialog-DNDsUU4y.js} +1 -1
- package/dist/ui/assets/{copilot-C9tvzWpP.js → copilot-BBSNM8Js.js} +1 -1
- package/dist/ui/assets/{cursor-7X2jg5OU.js → cursor-BvXE3nSI.js} +1 -1
- package/dist/ui/assets/{droid-CaVvAGBz.js → droid-CWtab_s9.js} +2 -2
- package/dist/ui/assets/{globalenv-section-rmwn4gBY.js → globalenv-section-CP0JmFSj.js} +1 -1
- package/dist/ui/assets/{health-YNma3ZU3.js → health-DTgTwM-s.js} +1 -1
- package/dist/ui/assets/{index-DwrnTADJ.js → index-CYp5jinD.js} +1 -1
- package/dist/ui/assets/{index-pvMXDZd2.js → index-D6rv02p-.js} +1 -1
- package/dist/ui/assets/{index-D_BsksCe.js → index-DHYYDVBg.js} +13 -13
- package/dist/ui/assets/{index-Cg7_zIGP.js → index-DK724WtF.js} +1 -1
- package/dist/ui/assets/{index-CtdI-JEv.js → index-De9YEKEj.js} +1 -1
- package/dist/ui/assets/{proxy-status-widget-D34hsuNr.js → proxy-status-widget-EXs54wf3.js} +1 -1
- package/dist/ui/assets/{searchable-select-BPNTu-Xv.js → searchable-select-BuZnRRH8.js} +1 -1
- package/dist/ui/assets/{separator-BAO8KZ_a.js → separator-4hxB22-j.js} +1 -1
- package/dist/ui/assets/{shared-Cz0YP1E_.js → shared-DbvNyqpe.js} +1 -1
- package/dist/ui/assets/{switch-DRdXtKAG.js → switch-BTxGr8Uo.js} +1 -1
- package/dist/ui/assets/{updates-DvZUO3G1.js → updates--csqglrd.js} +1 -1
- package/dist/ui/index.html +1 -1
- package/package.json +1 -1
- package/dist/ui/assets/cliproxy-D6WqAVUH.js +0 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.handleApiCommand = exports.parseApiCommandArgs = void 0;
|
|
3
|
+
exports.handleApiCommand = exports.createApiCommandHandler = exports.parseApiCommandArgs = void 0;
|
|
4
4
|
const named_command_router_1 = require("../named-command-router");
|
|
5
5
|
const copy_command_1 = require("./copy-command");
|
|
6
6
|
const create_command_1 = require("./create-command");
|
|
@@ -12,23 +12,47 @@ const list_command_1 = require("./list-command");
|
|
|
12
12
|
const remove_command_1 = require("./remove-command");
|
|
13
13
|
var shared_1 = require("./shared");
|
|
14
14
|
Object.defineProperty(exports, "parseApiCommandArgs", { enumerable: true, get: function () { return shared_1.parseApiCommandArgs; } });
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
15
|
+
const DEFAULT_API_COMMAND_DEPENDENCIES = {
|
|
16
|
+
help: help_1.showApiCommandHelp,
|
|
17
|
+
unknown: help_1.showUnknownApiCommand,
|
|
18
|
+
create: create_command_1.handleApiCreateCommand,
|
|
19
|
+
list: list_command_1.handleApiListCommand,
|
|
20
|
+
discover: discover_command_1.handleApiDiscoverCommand,
|
|
21
|
+
copy: copy_command_1.handleApiCopyCommand,
|
|
22
|
+
export: export_command_1.handleApiExportCommand,
|
|
23
|
+
import: import_command_1.handleApiImportCommand,
|
|
24
|
+
remove: remove_command_1.handleApiRemoveCommand,
|
|
25
|
+
};
|
|
26
|
+
function createApiCommandRoutes(dependencies) {
|
|
27
|
+
return [
|
|
28
|
+
{ name: 'create', handle: dependencies.create },
|
|
29
|
+
{ name: 'list', handle: dependencies.list },
|
|
30
|
+
{ name: 'discover', handle: dependencies.discover },
|
|
31
|
+
{ name: 'copy', handle: dependencies.copy },
|
|
32
|
+
{ name: 'export', handle: dependencies.export },
|
|
33
|
+
{ name: 'import', handle: dependencies.import },
|
|
34
|
+
{ name: 'remove', aliases: ['delete', 'rm'], handle: dependencies.remove },
|
|
35
|
+
];
|
|
36
|
+
}
|
|
37
|
+
function createApiCommandHandler(overrides = {}) {
|
|
38
|
+
const dependencies = {
|
|
39
|
+
...DEFAULT_API_COMMAND_DEPENDENCIES,
|
|
40
|
+
...overrides,
|
|
41
|
+
};
|
|
42
|
+
const routes = createApiCommandRoutes(dependencies);
|
|
43
|
+
return async (args) => {
|
|
44
|
+
await (0, named_command_router_1.dispatchNamedCommand)({
|
|
45
|
+
args,
|
|
46
|
+
routes,
|
|
47
|
+
onHelp: dependencies.help,
|
|
48
|
+
onUnknown: dependencies.unknown,
|
|
49
|
+
allowEmptyHelp: true,
|
|
50
|
+
});
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
exports.createApiCommandHandler = createApiCommandHandler;
|
|
24
54
|
async function handleApiCommand(args) {
|
|
25
|
-
await (
|
|
26
|
-
args,
|
|
27
|
-
routes: API_COMMAND_ROUTES,
|
|
28
|
-
onHelp: help_1.showApiCommandHelp,
|
|
29
|
-
onUnknown: help_1.showUnknownApiCommand,
|
|
30
|
-
allowEmptyHelp: true,
|
|
31
|
-
});
|
|
55
|
+
await createApiCommandHandler()(args);
|
|
32
56
|
}
|
|
33
57
|
exports.handleApiCommand = handleApiCommand;
|
|
34
58
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/api-command/index.ts"],"names":[],"mappings":";;;AAAA,kEAAuF;AACvF,iDAAsD;AACtD,qDAA0D;AAC1D,yDAA8D;AAC9D,qDAA0D;AAC1D,iCAAmE;AACnE,qDAA0D;AAC1D,iDAAsD;AACtD,qDAA0D;AAE1D,mCAA+C;AAAtC,6GAAA,mBAAmB,OAAA;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/api-command/index.ts"],"names":[],"mappings":";;;AAAA,kEAAuF;AACvF,iDAAsD;AACtD,qDAA0D;AAC1D,yDAA8D;AAC9D,qDAA0D;AAC1D,iCAAmE;AACnE,qDAA0D;AAC1D,iDAAsD;AACtD,qDAA0D;AAE1D,mCAA+C;AAAtC,6GAAA,mBAAmB,OAAA;AAkB5B,MAAM,gCAAgC,GAA2B;IAC/D,IAAI,EAAE,yBAAkB;IACxB,OAAO,EAAE,4BAAqB;IAC9B,MAAM,EAAE,uCAAsB;IAC9B,IAAI,EAAE,mCAAoB;IAC1B,QAAQ,EAAE,2CAAwB;IAClC,IAAI,EAAE,mCAAoB;IAC1B,MAAM,EAAE,uCAAsB;IAC9B,MAAM,EAAE,uCAAsB;IAC9B,MAAM,EAAE,uCAAsB;CAC/B,CAAC;AAEF,SAAS,sBAAsB,CAC7B,YAAoC;IAEpC,OAAO;QACL,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAY,CAAC,MAAM,EAAE;QAC/C,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,CAAC,IAAI,EAAE;QAC3C,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,YAAY,CAAC,QAAQ,EAAE;QACnD,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,CAAC,IAAI,EAAE;QAC3C,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAY,CAAC,MAAM,EAAE;QAC/C,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAY,CAAC,MAAM,EAAE;QAC/C,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC,QAAQ,EAAE,IAAI,CAAC,EAAE,MAAM,EAAE,YAAY,CAAC,MAAM,EAAE;KAC3E,CAAC;AACJ,CAAC;AAED,SAAgB,uBAAuB,CACrC,YAA6C,EAAE;IAE/C,MAAM,YAAY,GAA2B;QAC3C,GAAG,gCAAgC;QACnC,GAAG,SAAS;KACb,CAAC;IACF,MAAM,MAAM,GAAG,sBAAsB,CAAC,YAAY,CAAC,CAAC;IAEpD,OAAO,KAAK,EAAE,IAAc,EAAE,EAAE;QAC9B,MAAM,IAAA,2CAAoB,EAAC;YACzB,IAAI;YACJ,MAAM;YACN,MAAM,EAAE,YAAY,CAAC,IAAI;YACzB,SAAS,EAAE,YAAY,CAAC,OAAO;YAC/B,cAAc,EAAE,IAAI;SACrB,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC;AAlBD,0DAkBC;AAEM,KAAK,UAAU,gBAAgB,CAAC,IAAc;IACnD,MAAM,uBAAuB,EAAE,CAAC,IAAI,CAAC,CAAC;AACxC,CAAC;AAFD,4CAEC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ModelMapping } from '../../api/services';
|
|
1
2
|
import type { TargetType } from '../../targets/target-adapter';
|
|
2
3
|
export interface ApiCommandArgs {
|
|
3
4
|
name?: string;
|
|
@@ -8,11 +9,12 @@ export interface ApiCommandArgs {
|
|
|
8
9
|
preset?: string;
|
|
9
10
|
cliproxyProvider?: string;
|
|
10
11
|
target?: TargetType;
|
|
12
|
+
extendedContext?: boolean;
|
|
11
13
|
force?: boolean;
|
|
12
14
|
yes?: boolean;
|
|
13
15
|
errors: string[];
|
|
14
16
|
}
|
|
15
|
-
export declare const API_BOOLEAN_FLAGS: readonly ["--force", "--yes", "-y"];
|
|
17
|
+
export declare const API_BOOLEAN_FLAGS: readonly ["--force", "--yes", "-y", "--1m", "--no-1m"];
|
|
16
18
|
export declare const API_VALUE_FLAGS: readonly ["--base-url", "--api-key", "--model", "--preset", "--cliproxy-provider", "--target"];
|
|
17
19
|
export declare const API_KNOWN_FLAGS: readonly string[];
|
|
18
20
|
export interface ParseApiCommandArgsOptions {
|
|
@@ -33,5 +35,8 @@ export declare function collectUnexpectedApiArgs(args: string[], options: {
|
|
|
33
35
|
errors: string[];
|
|
34
36
|
};
|
|
35
37
|
export declare function parseApiCommandArgs(args: string[], options?: ParseApiCommandArgsOptions): ApiCommandArgs;
|
|
38
|
+
export declare function hasClaudeModelMapping(models: ModelMapping): boolean;
|
|
39
|
+
export declare function hasExplicitClaudeExtendedContext(models: ModelMapping): boolean;
|
|
40
|
+
export declare function applyClaudeExtendedContextPreference(models: ModelMapping, enabled: boolean): ModelMapping;
|
|
36
41
|
export declare function exitOnApiCommandErrors(errors: string[]): void;
|
|
37
42
|
//# sourceMappingURL=shared.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../../src/commands/api-command/shared.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../../src/commands/api-command/shared.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AACvD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAW/D,MAAM,WAAW,cAAc;IAC7B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,MAA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C,CAClD,MAAM,EAAE,YAAY,EACpB,OAAO,EAAE,OAAO,GACf,YAAY,CAgBd;AAED,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,CAS7D"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.exitOnApiCommandErrors = exports.parseApiCommandArgs = exports.collectUnexpectedApiArgs = exports.parseOptionalTargetFlag = exports.extractPositionalArgs = exports.sanitizeHelpText = exports.API_KNOWN_FLAGS = exports.API_VALUE_FLAGS = exports.API_BOOLEAN_FLAGS = void 0;
|
|
3
|
+
exports.exitOnApiCommandErrors = exports.applyClaudeExtendedContextPreference = exports.hasExplicitClaudeExtendedContext = exports.hasClaudeModelMapping = exports.parseApiCommandArgs = exports.collectUnexpectedApiArgs = exports.parseOptionalTargetFlag = exports.extractPositionalArgs = exports.sanitizeHelpText = exports.API_KNOWN_FLAGS = exports.API_VALUE_FLAGS = exports.API_BOOLEAN_FLAGS = void 0;
|
|
4
|
+
const extended_context_utils_1 = require("../../shared/extended-context-utils");
|
|
4
5
|
const ui_1 = require("../../utils/ui");
|
|
5
6
|
const arg_extractor_1 = require("../arg-extractor");
|
|
6
|
-
|
|
7
|
+
const MODEL_MAPPING_KEYS = ['default', 'opus', 'sonnet', 'haiku'];
|
|
8
|
+
exports.API_BOOLEAN_FLAGS = ['--force', '--yes', '-y', '--1m', '--no-1m'];
|
|
7
9
|
exports.API_VALUE_FLAGS = [
|
|
8
10
|
'--base-url',
|
|
9
11
|
'--api-key',
|
|
@@ -105,12 +107,23 @@ function collectUnexpectedApiArgs(args, options) {
|
|
|
105
107
|
}
|
|
106
108
|
exports.collectUnexpectedApiArgs = collectUnexpectedApiArgs;
|
|
107
109
|
function parseApiCommandArgs(args, options = {}) {
|
|
110
|
+
const enableExtendedContext = (0, arg_extractor_1.hasAnyFlag)(args, ['--1m']);
|
|
111
|
+
const disableExtendedContext = (0, arg_extractor_1.hasAnyFlag)(args, ['--no-1m']);
|
|
108
112
|
const result = {
|
|
109
113
|
positionals: [],
|
|
110
114
|
force: (0, arg_extractor_1.hasAnyFlag)(args, ['--force']),
|
|
111
115
|
yes: (0, arg_extractor_1.hasAnyFlag)(args, ['--yes', '-y']),
|
|
112
116
|
errors: [],
|
|
113
117
|
};
|
|
118
|
+
if (enableExtendedContext && disableExtendedContext) {
|
|
119
|
+
result.errors.push('Cannot combine --1m and --no-1m');
|
|
120
|
+
}
|
|
121
|
+
else if (enableExtendedContext) {
|
|
122
|
+
result.extendedContext = true;
|
|
123
|
+
}
|
|
124
|
+
else if (disableExtendedContext) {
|
|
125
|
+
result.extendedContext = false;
|
|
126
|
+
}
|
|
114
127
|
let remaining = [...args];
|
|
115
128
|
remaining = applyRepeatedOption(remaining, ['--base-url'], (value) => {
|
|
116
129
|
result.baseUrl = value;
|
|
@@ -157,6 +170,29 @@ function parseApiCommandArgs(args, options = {}) {
|
|
|
157
170
|
return result;
|
|
158
171
|
}
|
|
159
172
|
exports.parseApiCommandArgs = parseApiCommandArgs;
|
|
173
|
+
function hasClaudeModelMapping(models) {
|
|
174
|
+
return MODEL_MAPPING_KEYS.some((key) => (0, extended_context_utils_1.isClaudeModelId)(models[key]));
|
|
175
|
+
}
|
|
176
|
+
exports.hasClaudeModelMapping = hasClaudeModelMapping;
|
|
177
|
+
function hasExplicitClaudeExtendedContext(models) {
|
|
178
|
+
return MODEL_MAPPING_KEYS.some((key) => (0, extended_context_utils_1.isClaudeModelId)(models[key]) && (0, extended_context_utils_1.hasExtendedContextSuffix)(models[key]));
|
|
179
|
+
}
|
|
180
|
+
exports.hasExplicitClaudeExtendedContext = hasExplicitClaudeExtendedContext;
|
|
181
|
+
function applyClaudeExtendedContextPreference(models, enabled) {
|
|
182
|
+
const nextModels = { ...models };
|
|
183
|
+
for (const key of MODEL_MAPPING_KEYS) {
|
|
184
|
+
const value = nextModels[key];
|
|
185
|
+
if (!(0, extended_context_utils_1.isClaudeModelId)(value)) {
|
|
186
|
+
continue;
|
|
187
|
+
}
|
|
188
|
+
nextModels[key] =
|
|
189
|
+
enabled && (0, extended_context_utils_1.likelySupportsClaudeExtendedContext)(value)
|
|
190
|
+
? (0, extended_context_utils_1.applyExtendedContextSuffix)(value)
|
|
191
|
+
: (0, extended_context_utils_1.stripExtendedContextSuffix)(value);
|
|
192
|
+
}
|
|
193
|
+
return nextModels;
|
|
194
|
+
}
|
|
195
|
+
exports.applyClaudeExtendedContextPreference = applyClaudeExtendedContextPreference;
|
|
160
196
|
function exitOnApiCommandErrors(errors) {
|
|
161
197
|
if (errors.length === 0) {
|
|
162
198
|
return;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../src/commands/api-command/shared.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../src/commands/api-command/shared.ts"],"names":[],"mappings":";;;AAEA,gFAM6C;AAC7C,uCAAsC;AACtC,oDAA8E;AAiB9E,MAAM,kBAAkB,GAAG,CAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,CAAU,CAAC;AAE9D,QAAA,iBAAiB,GAAG,CAAC,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,CAAU,CAAC;AAC3E,QAAA,eAAe,GAAG;IAC7B,YAAY;IACZ,WAAW;IACX,SAAS;IACT,UAAU;IACV,qBAAqB;IACrB,UAAU;CACF,CAAC;AACE,QAAA,eAAe,GAAsB,CAAC,GAAG,yBAAiB,EAAE,GAAG,uBAAe,CAAC,CAAC;AAE7F,MAAM,kBAAkB,GAAG,IAAI,GAAG,CAAS,uBAAe,CAAC,CAAC;AAM5D,SAAgB,gBAAgB,CAAC,KAAa;IAC5C,OAAO,KAAK;SACT,OAAO,CAAC,YAAY,EAAE,GAAG,CAAC;SAC1B,OAAO,CAAC,kBAAkB,EAAE,GA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ACT,CAAC;IAED,MAAM,CAAC,OAAO,CAAC,CAAC,YAAY,EAAE,EAAE;QAC9B,OAAO,CAAC,GAAG,CAAC,IAAA,SAAI,EAAC,YAAY,CAAC,CAAC,CAAC;IAClC,CAAC,CAAC,CAAC;IACH,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC;AATD,wDASC"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
type HelpWriter = (line: string) => void;
|
|
1
2
|
/**
|
|
2
3
|
* Display comprehensive help information for CCS (Claude Code Switch)
|
|
3
4
|
*/
|
|
4
|
-
export declare function handleHelpCommand(): Promise<void>;
|
|
5
|
+
export declare function handleHelpCommand(writeLine?: HelpWriter): Promise<void>;
|
|
6
|
+
export {};
|
|
5
7
|
//# sourceMappingURL=help-command.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"help-command.d.ts","sourceRoot":"","sources":["../../src/commands/help-command.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"help-command.d.ts","sourceRoot":"","sources":["../../src/commands/help-command.ts"],"names":[],"mappings":"AAOA,KAAK,UAAU,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AA+FzC;;GAEG;AACH,wBAAsB,iBAAiB,CAAC,SAAS,GAAE,UAAwB,GAAG,OAAO,CAAC,IAAI,CAAC,CAqiB1F"}
|
|
@@ -41,23 +41,23 @@ const VERSION = JSON.parse(fs.readFileSync(path.join(__dirname, '../../package.j
|
|
|
41
41
|
*
|
|
42
42
|
* command Description
|
|
43
43
|
*/
|
|
44
|
-
function printMajorSection(title, subtitles, items) {
|
|
44
|
+
function printMajorSection(title, subtitles, items, writeLine = console.log) {
|
|
45
45
|
// Section header with ═══ borders
|
|
46
|
-
|
|
46
|
+
writeLine((0, ui_1.sectionHeader)(title));
|
|
47
47
|
// Subtitles on separate lines (dim)
|
|
48
48
|
for (const subtitle of subtitles) {
|
|
49
|
-
|
|
49
|
+
writeLine(` ${(0, ui_1.dim)(subtitle)}`);
|
|
50
50
|
}
|
|
51
51
|
// Empty line before items
|
|
52
|
-
|
|
52
|
+
writeLine('');
|
|
53
53
|
// Calculate max command length for alignment
|
|
54
54
|
const maxCmdLen = Math.max(...items.map(([cmd]) => cmd.length));
|
|
55
55
|
for (const [cmd, desc] of items) {
|
|
56
56
|
const paddedCmd = cmd.padEnd(maxCmdLen + 2);
|
|
57
|
-
|
|
57
|
+
writeLine(` ${(0, ui_1.color)(paddedCmd, 'command')} ${desc}`);
|
|
58
58
|
}
|
|
59
59
|
// Extra spacing after section
|
|
60
|
-
|
|
60
|
+
writeLine('');
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* Print a sub-section with colored title
|
|
@@ -65,17 +65,17 @@ function printMajorSection(title, subtitles, items) {
|
|
|
65
65
|
* Title (context):
|
|
66
66
|
* command Description
|
|
67
67
|
*/
|
|
68
|
-
function printSubSection(title, items) {
|
|
68
|
+
function printSubSection(title, items, writeLine = console.log) {
|
|
69
69
|
// Sub-section header (colored, no borders)
|
|
70
|
-
|
|
70
|
+
writeLine((0, ui_1.subheader)(`${title}:`));
|
|
71
71
|
// Calculate max command length for alignment
|
|
72
72
|
const maxCmdLen = Math.max(...items.map(([cmd]) => cmd.length));
|
|
73
73
|
for (const [cmd, desc] of items) {
|
|
74
74
|
const paddedCmd = cmd.padEnd(maxCmdLen + 2);
|
|
75
|
-
|
|
75
|
+
writeLine(` ${(0, ui_1.color)(paddedCmd, 'command')} ${desc}`);
|
|
76
76
|
}
|
|
77
77
|
// Spacing after section
|
|
78
|
-
|
|
78
|
+
writeLine('');
|
|
79
79
|
}
|
|
80
80
|
/**
|
|
81
81
|
* Print a config/paths section
|
|
@@ -83,20 +83,20 @@ function printSubSection(title, items) {
|
|
|
83
83
|
* Title:
|
|
84
84
|
* Label: path
|
|
85
85
|
*/
|
|
86
|
-
function printConfigSection(title, items) {
|
|
87
|
-
|
|
86
|
+
function printConfigSection(title, items, writeLine = console.log) {
|
|
87
|
+
writeLine((0, ui_1.subheader)(`${title}:`));
|
|
88
88
|
// Calculate max label length for alignment
|
|
89
89
|
const maxLabelLen = Math.max(...items.map(([label]) => label.length));
|
|
90
90
|
for (const [label, path] of items) {
|
|
91
91
|
const paddedLabel = label.padEnd(maxLabelLen);
|
|
92
|
-
|
|
92
|
+
writeLine(` ${paddedLabel} ${(0, ui_1.color)(path, 'path')}`);
|
|
93
93
|
}
|
|
94
|
-
|
|
94
|
+
writeLine('');
|
|
95
95
|
}
|
|
96
96
|
/**
|
|
97
97
|
* Display comprehensive help information for CCS (Claude Code Switch)
|
|
98
98
|
*/
|
|
99
|
-
async function handleHelpCommand() {
|
|
99
|
+
async function handleHelpCommand(writeLine = console.log) {
|
|
100
100
|
// Initialize UI (if not already)
|
|
101
101
|
await (0, ui_1.initUI)();
|
|
102
102
|
// Hero box with ASCII art logo and config hint
|
|
@@ -109,20 +109,20 @@ async function handleHelpCommand() {
|
|
|
109
109
|
Claude Code Profile & Model Switcher
|
|
110
110
|
|
|
111
111
|
Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
112
|
-
|
|
112
|
+
writeLine((0, ui_1.box)(logo, {
|
|
113
113
|
padding: 1,
|
|
114
114
|
borderStyle: 'round',
|
|
115
115
|
titleAlignment: 'center',
|
|
116
116
|
}));
|
|
117
|
-
|
|
117
|
+
writeLine('');
|
|
118
118
|
// Resolve display path for dynamic sections
|
|
119
119
|
const [dirSource] = (0, config_manager_1.getCcsDirSource)();
|
|
120
120
|
const dirDisplay = dirSource === 'default' ? '~/.ccs' : (0, config_manager_1.getCcsDir)();
|
|
121
121
|
// Usage section
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
122
|
+
writeLine((0, ui_1.subheader)('Usage:'));
|
|
123
|
+
writeLine(` ${(0, ui_1.color)('ccs', 'command')} [profile] [claude-args...]`);
|
|
124
|
+
writeLine(` ${(0, ui_1.color)('ccs', 'command')} [flags]`);
|
|
125
|
+
writeLine('');
|
|
126
126
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
127
127
|
// MAJOR SECTION 1: API Key Profiles
|
|
128
128
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
@@ -150,7 +150,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
150
150
|
['ccs api import <file>', 'Import profile bundle'],
|
|
151
151
|
['ccs api remove', 'Remove an API profile'],
|
|
152
152
|
['ccs api list', 'List all API profiles'],
|
|
153
|
-
]);
|
|
153
|
+
], writeLine);
|
|
154
154
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
155
155
|
// MAJOR SECTION 2: Account Management
|
|
156
156
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
@@ -169,7 +169,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
169
169
|
['ccs auth default <name>', 'Set default profile'],
|
|
170
170
|
['ccs auth reset-default', 'Restore original CCS default'],
|
|
171
171
|
['ccs cliproxy auth claude', 'Alternative: authenticate Claude account pool via CLIProxy'],
|
|
172
|
-
]);
|
|
172
|
+
], writeLine);
|
|
173
173
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
174
174
|
// MAJOR SECTION 3: CLI Proxy (OAuth Providers)
|
|
175
175
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
@@ -208,8 +208,8 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
208
208
|
'Set thinking budget (low/medium/high/xhigh/auto/off or number)',
|
|
209
209
|
],
|
|
210
210
|
['ccs codex --effort <level>', 'Set codex reasoning effort (medium/high/xhigh)'],
|
|
211
|
-
['ccs <provider> --1m', '
|
|
212
|
-
['ccs <provider> --no-1m', '
|
|
211
|
+
['ccs <provider> --1m', 'Request explicit 1M context when the selected model supports [1m]'],
|
|
212
|
+
['ccs <provider> --no-1m', 'Force standard context / clear [1m]'],
|
|
213
213
|
['ccs <provider> --logout', 'Clear authentication'],
|
|
214
214
|
['ccs <provider> --headless', 'Headless auth (for SSH)'],
|
|
215
215
|
['ccs <provider> --port-forward', 'Force port-forwarding mode (skip prompt)'],
|
|
@@ -220,7 +220,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
220
220
|
['ccs kiro --import', 'Import token from Kiro IDE'],
|
|
221
221
|
['ccs kiro --incognito', 'Use incognito browser (default: normal)'],
|
|
222
222
|
['ccs codex "explain code"', 'Use with prompt'],
|
|
223
|
-
]);
|
|
223
|
+
], writeLine);
|
|
224
224
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
225
225
|
// MAJOR SECTION 4: GitHub Copilot Integration (copilot-api)
|
|
226
226
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
@@ -238,7 +238,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
238
238
|
['ccs copilot stop', 'Stop copilot-api daemon'],
|
|
239
239
|
['ccs copilot enable', 'Enable integration'],
|
|
240
240
|
['ccs copilot disable', 'Disable integration'],
|
|
241
|
-
]);
|
|
241
|
+
], writeLine);
|
|
242
242
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
243
243
|
// MAJOR SECTION 5: Cursor IDE Integration
|
|
244
244
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
@@ -255,7 +255,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
255
255
|
['ccs cursor stop', 'Stop proxy daemon'],
|
|
256
256
|
['ccs cursor enable', 'Enable cursor integration'],
|
|
257
257
|
['ccs cursor disable', 'Disable cursor integration'],
|
|
258
|
-
]);
|
|
258
|
+
], writeLine);
|
|
259
259
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
260
260
|
// SUB-SECTIONS (simpler styling)
|
|
261
261
|
// ═══════════════════════════════════════════════════════════════════════════
|
|
@@ -266,7 +266,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
266
266
|
['/ccs --kimi "task"', 'Force Kimi OAuth for long context'],
|
|
267
267
|
['/ccs --km "task"', 'Force Kimi API key for long context'],
|
|
268
268
|
['/ccs:continue "follow-up"', 'Continue last delegation session'],
|
|
269
|
-
]);
|
|
269
|
+
], writeLine);
|
|
270
270
|
// Delegation CLI Flags (Claude Code passthrough)
|
|
271
271
|
printSubSection('Delegation Flags (Claude Code passthrough)', [
|
|
272
272
|
['--max-turns <n>', 'Limit agentic turns (prevents loops)'],
|
|
@@ -275,7 +275,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
275
275
|
['--betas <features>', 'Enable experimental features'],
|
|
276
276
|
['--allowedTools <list>', 'Restrict available tools'],
|
|
277
277
|
['--disallowedTools <list>', 'Block specific tools'],
|
|
278
|
-
]);
|
|
278
|
+
], writeLine);
|
|
279
279
|
// Diagnostics
|
|
280
280
|
printSubSection('Diagnostics', [
|
|
281
281
|
['ccs setup', 'First-time setup wizard'],
|
|
@@ -304,7 +304,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
304
304
|
['ccs update', 'Update CCS to latest version'],
|
|
305
305
|
['ccs update --force', 'Force reinstall current version'],
|
|
306
306
|
['ccs update --beta', 'Install from dev channel (unstable)'],
|
|
307
|
-
]);
|
|
307
|
+
], writeLine);
|
|
308
308
|
// Environment export
|
|
309
309
|
printSubSection('Environment Export', [
|
|
310
310
|
['ccs env <profile>', 'Export env vars for third-party tools'],
|
|
@@ -320,7 +320,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
320
320
|
'Windsurf Claude extension settings JSON',
|
|
321
321
|
],
|
|
322
322
|
['ccs env <profile> --shell fish', 'Fish shell syntax'],
|
|
323
|
-
]);
|
|
323
|
+
], writeLine);
|
|
324
324
|
// Flags
|
|
325
325
|
printSubSection('Flags', [
|
|
326
326
|
['--config-dir <path>', 'Use custom CCS config directory'],
|
|
@@ -328,12 +328,12 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
328
328
|
['-h, --help', 'Show this help message'],
|
|
329
329
|
['-v, --version', 'Show version and installation info'],
|
|
330
330
|
['-sc, --shell-completion', 'Install shell auto-completion'],
|
|
331
|
-
]);
|
|
331
|
+
], writeLine);
|
|
332
332
|
// Aliases
|
|
333
333
|
printSubSection('Aliases', [
|
|
334
334
|
['ccs-droid <profile> [args]', 'Explicit Droid runtime alias'],
|
|
335
335
|
['ccsd <profile> [args]', 'Legacy shortcut for: ccs-droid <profile> [args]'],
|
|
336
|
-
]);
|
|
336
|
+
], writeLine);
|
|
337
337
|
// Multi-target examples
|
|
338
338
|
printSubSection('Multi-Target', [
|
|
339
339
|
['ccs glm --target droid', 'Run GLM profile on Droid CLI'],
|
|
@@ -345,7 +345,10 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
345
345
|
'ccs-droid codex exec --skip-permissions-unsafe "fix failing tests"',
|
|
346
346
|
'Pass through Droid exec mode',
|
|
347
347
|
],
|
|
348
|
-
[
|
|
348
|
+
[
|
|
349
|
+
'ccs-droid codex -m custom:gpt-5.3-codex "fix failing tests"',
|
|
350
|
+
'Auto-routes short exec flags',
|
|
351
|
+
],
|
|
349
352
|
[
|
|
350
353
|
'ccs-droid codex --skip-permissions-unsafe "fix failing tests"',
|
|
351
354
|
'Auto-routes to Droid exec when exec-only flags are detected',
|
|
@@ -355,14 +358,14 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
355
358
|
'Create CLIProxy variant with Droid as default target',
|
|
356
359
|
],
|
|
357
360
|
['ccs glm', 'Run GLM profile on Claude Code (default)'],
|
|
358
|
-
]);
|
|
361
|
+
], writeLine);
|
|
359
362
|
// Configuration
|
|
360
363
|
printConfigSection('Configuration', [
|
|
361
364
|
['Config File:', (0, unified_config_loader_1.isUnifiedMode)() ? `${dirDisplay}/config.yaml` : `${dirDisplay}/config.json`],
|
|
362
365
|
['Profiles:', `${dirDisplay}/profiles.json`],
|
|
363
366
|
['Instances:', `${dirDisplay}/instances/`],
|
|
364
367
|
['Settings:', `${dirDisplay}/*.settings.json`],
|
|
365
|
-
]);
|
|
368
|
+
], writeLine);
|
|
366
369
|
// CLI Proxy management
|
|
367
370
|
printSubSection('CLI Proxy Plus Management', [
|
|
368
371
|
['ccs cliproxy', 'Show CLIProxy Plus status and version'],
|
|
@@ -376,7 +379,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
376
379
|
['ccs cliproxy status', 'Show CLIProxy process status'],
|
|
377
380
|
['ccs cliproxy quota', 'Show quota/tier/pause status for all providers'],
|
|
378
381
|
['ccs cliproxy quota --provider <name>', 'Show quota/tier/pause status for one provider'],
|
|
379
|
-
]);
|
|
382
|
+
], writeLine);
|
|
380
383
|
// CLI Proxy configuration flags (new)
|
|
381
384
|
printSubSection('CLI Proxy Configuration', [
|
|
382
385
|
['--proxy-host <host>', 'Remote proxy hostname/IP'],
|
|
@@ -387,7 +390,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
387
390
|
['--local-proxy', 'Force local mode, ignore remote config'],
|
|
388
391
|
['--remote-only', 'Fail if remote unreachable (no fallback)'],
|
|
389
392
|
['--allow-self-signed', 'Allow self-signed certs (for dev proxies)'],
|
|
390
|
-
]);
|
|
393
|
+
], writeLine);
|
|
391
394
|
// W3: Thinking Budget explanation
|
|
392
395
|
printSubSection('Extended Thinking / Reasoning', [
|
|
393
396
|
['--thinking off', 'Disable extended thinking'],
|
|
@@ -410,18 +413,22 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
410
413
|
['', 'before responding.'],
|
|
411
414
|
['', 'Providers: agy/gemini use --thinking, codex uses --effort (or --thinking alias).'],
|
|
412
415
|
['', 'Codex model suffixes also pin effort: -medium / -high / -xhigh.'],
|
|
413
|
-
]);
|
|
416
|
+
], writeLine);
|
|
414
417
|
// Extended Context (1M)
|
|
415
418
|
printSubSection('Extended Context (--1m)', [
|
|
416
|
-
['--1m', '
|
|
417
|
-
['--no-1m', '
|
|
419
|
+
['--1m', 'Request 1M token context when the selected model supports [1m]'],
|
|
420
|
+
['--no-1m', 'Force standard context (Claude default stays plain)'],
|
|
418
421
|
['', ''],
|
|
419
|
-
['Auto behavior:', 'Gemini models: auto-
|
|
420
|
-
['', 'Claude models: opt-in with --1m
|
|
422
|
+
['Auto behavior:', 'Gemini models: CCS auto-adds [1m] when supported'],
|
|
423
|
+
['', 'Claude models: plain by default, opt-in with --1m or saved [1m]'],
|
|
421
424
|
['', ''],
|
|
422
|
-
['Note:', '
|
|
423
|
-
['', '
|
|
424
|
-
|
|
425
|
+
['Note:', 'CCS only controls the saved [1m] suffix.'],
|
|
426
|
+
['', 'Provider pricing and entitlement stay upstream.'],
|
|
427
|
+
[
|
|
428
|
+
'',
|
|
429
|
+
'Some accounts/providers can still return 429 extra-usage errors for long-context requests.',
|
|
430
|
+
],
|
|
431
|
+
], writeLine);
|
|
425
432
|
// Image Analysis
|
|
426
433
|
printSubSection('Image Analysis (CLIProxy vision)', [
|
|
427
434
|
['ccs config image-analysis', 'Show current settings'],
|
|
@@ -433,7 +440,7 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
433
440
|
['Note:', 'When enabled, images/PDFs are analyzed via vision models'],
|
|
434
441
|
['', 'instead of passing raw data to Claude. Works with CLIProxy'],
|
|
435
442
|
['', 'providers (agy, gemini, codex, kiro, ghcp).'],
|
|
436
|
-
]);
|
|
443
|
+
], writeLine);
|
|
437
444
|
printSubSection('Official Channels (official Claude plugins)', [
|
|
438
445
|
['ccs config', 'Dashboard -> Settings -> Channels (fastest path)'],
|
|
439
446
|
['ccs config channels', 'Show current status'],
|
|
@@ -453,14 +460,14 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
453
460
|
['', 'Telegram/Discord tokens live in ~/.claude/channels/<channel>/.env.'],
|
|
454
461
|
['', 'Current-process TELEGRAM_BOT_TOKEN / DISCORD_BOT_TOKEN also work for that launch.'],
|
|
455
462
|
['', 'iMessage is macOS-only and requires local OS permissions instead of a bot token.'],
|
|
456
|
-
]);
|
|
463
|
+
], writeLine);
|
|
457
464
|
// CCS Environment Variables
|
|
458
465
|
printSubSection('Environment Variables', [
|
|
459
466
|
['CCS_DIR', 'Override CCS config directory (default: ~/.ccs)'],
|
|
460
467
|
['CCS_HOME', 'Override home directory (legacy, appends .ccs)'],
|
|
461
468
|
['CCS_DEBUG', 'Enable debug logging'],
|
|
462
469
|
['CCS_THINKING', 'Override thinking level (flag > env > config)'],
|
|
463
|
-
]);
|
|
470
|
+
], writeLine);
|
|
464
471
|
// CLI Proxy env vars
|
|
465
472
|
printSubSection('CLI Proxy Environment Variables', [
|
|
466
473
|
['CCS_PROXY_HOST', 'Remote proxy hostname'],
|
|
@@ -470,44 +477,44 @@ Run ${(0, ui_1.color)('ccs config', 'command')} for web dashboard`.trim();
|
|
|
470
477
|
['CCS_PROXY_TIMEOUT', 'Connection timeout in ms'],
|
|
471
478
|
['CCS_PROXY_FALLBACK_ENABLED', 'Enable local fallback (1/0)'],
|
|
472
479
|
['CCS_ALLOW_SELF_SIGNED', 'Allow self-signed certs (1/0)'],
|
|
473
|
-
]);
|
|
480
|
+
], writeLine);
|
|
474
481
|
// CLI Proxy paths
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
482
|
+
writeLine((0, ui_1.subheader)('CLI Proxy:'));
|
|
483
|
+
writeLine(` Binary: ${(0, ui_1.color)(`${dirDisplay}/cliproxy/bin/cli-proxy-api-plus`, 'path')}`);
|
|
484
|
+
writeLine(` Config: ${(0, ui_1.color)(`${dirDisplay}/cliproxy/config.yaml`, 'path')}`);
|
|
485
|
+
writeLine(` Auth: ${(0, ui_1.color)(`${dirDisplay}/cliproxy/auth/`, 'path')}`);
|
|
486
|
+
writeLine(` ${(0, ui_1.dim)(`Port: ${port_manager_1.CLIPROXY_DEFAULT_PORT} (default)`)}`);
|
|
487
|
+
writeLine('');
|
|
481
488
|
// Shared Data
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
489
|
+
writeLine((0, ui_1.subheader)('Shared Data:'));
|
|
490
|
+
writeLine(` Commands: ${(0, ui_1.color)(`${dirDisplay}/shared/commands/`, 'path')}`);
|
|
491
|
+
writeLine(` Skills: ${(0, ui_1.color)(`${dirDisplay}/shared/skills/`, 'path')}`);
|
|
492
|
+
writeLine(` Agents: ${(0, ui_1.color)(`${dirDisplay}/shared/agents/`, 'path')}`);
|
|
493
|
+
writeLine(` ${(0, ui_1.dim)('Note: Symlinked across all profiles')}`);
|
|
494
|
+
writeLine('');
|
|
488
495
|
// Examples (aligned with consistent spacing)
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
496
|
+
writeLine((0, ui_1.subheader)('Examples:'));
|
|
497
|
+
writeLine(` $ ${(0, ui_1.color)('ccs', 'command')} ${(0, ui_1.dim)('# Use default account')}`);
|
|
498
|
+
writeLine(` $ ${(0, ui_1.color)('ccs gemini', 'command')} ${(0, ui_1.dim)('# OAuth (browser opens first time)')}`);
|
|
499
|
+
writeLine(` $ ${(0, ui_1.color)('ccs glm "implement API"', 'command')} ${(0, ui_1.dim)('# API key model')}`);
|
|
500
|
+
writeLine(` $ ${(0, ui_1.color)('ccs config', 'command')} ${(0, ui_1.dim)('# Open web dashboard')}`);
|
|
501
|
+
writeLine('');
|
|
495
502
|
// Update examples
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
503
|
+
writeLine((0, ui_1.subheader)('Update:'));
|
|
504
|
+
writeLine(` $ ${(0, ui_1.color)('ccs update', 'command')} ${(0, ui_1.dim)('# Update to latest stable')}`);
|
|
505
|
+
writeLine(` $ ${(0, ui_1.color)('ccs update --force', 'command')} ${(0, ui_1.dim)('# Force reinstall current')}`);
|
|
506
|
+
writeLine(` $ ${(0, ui_1.color)('ccs update --beta', 'command')} ${(0, ui_1.dim)('# Install dev channel')}`);
|
|
507
|
+
writeLine('');
|
|
501
508
|
// Docs link
|
|
502
|
-
|
|
503
|
-
|
|
509
|
+
writeLine(` ${(0, ui_1.dim)('Docs: https://github.com/kaitranntt/ccs')}`);
|
|
510
|
+
writeLine('');
|
|
504
511
|
// Uninstall
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
512
|
+
writeLine((0, ui_1.subheader)('Uninstall:'));
|
|
513
|
+
writeLine(` ${(0, ui_1.color)('npm uninstall -g @kaitranntt/ccs', 'command')}`);
|
|
514
|
+
writeLine('');
|
|
508
515
|
// License
|
|
509
|
-
|
|
510
|
-
|
|
516
|
+
writeLine((0, ui_1.dim)('License: MIT'));
|
|
517
|
+
writeLine('');
|
|
511
518
|
}
|
|
512
519
|
exports.handleHelpCommand = handleHelpCommand;
|
|
513
520
|
//# sourceMappingURL=help-command.js.map
|