@botconnector/bccli 0.4.0-beta.9 → 0.4.0
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/README.en.md +242 -0
- package/README.md +80 -4
- package/dist/acp-ATIL4JOZ.js +182 -0
- package/dist/args-J5ONVGIF.js +13 -0
- package/dist/chunk-45SDLMTV.js +341 -0
- package/dist/chunk-6M5X2KZE.js +8 -0
- package/dist/chunk-7F3IWBPQ.js +191 -0
- package/dist/{chunk-CLN4Z5E3.js → chunk-BLOYFIAD.js} +6 -3
- package/dist/chunk-BNA74HPN.js +145 -0
- package/dist/{chunk-DX7CZTBB.js → chunk-BQ2IGPBR.js} +14 -9
- package/dist/chunk-JL5ZCSP2.js +76 -0
- package/dist/chunk-KEMYIGCP.js +235 -0
- package/dist/{chunk-BFZXRKW5.js → chunk-L7QI6JN2.js} +24 -2
- package/dist/chunk-LACUWBWS.js +361 -0
- package/dist/chunk-M7CALSP3.js +733 -0
- package/dist/{chunk-ELML4KVQ.js → chunk-O7M3TGIW.js} +34 -2
- package/dist/chunk-PSO7R5AD.js +10 -0
- package/dist/chunk-PUN4HMAG.js +940 -0
- package/dist/{chunk-SJH3YLW4.js → chunk-QDQU6VY2.js} +60 -6
- package/dist/chunk-QZKLZELZ.js +64 -0
- package/dist/{chunk-7S6JXQCH.js → chunk-SPRNLS7K.js} +2 -1
- package/dist/chunk-TLPFQIS2.js +231 -0
- package/dist/chunk-TVALKHFB.js +2143 -0
- package/dist/chunk-UZWJQF67.js +500 -0
- package/dist/chunk-XBO5GACQ.js +56 -0
- package/dist/cli.js +151 -1382
- package/dist/completion-HPPFDAPB.js +125 -0
- package/dist/{config-YUNKPCNB.js → config-COPNMMV6.js} +5 -2
- package/dist/config-RZ5JONMX.js +30 -0
- package/dist/ghBotCli-IBCZIWT5.js +677 -0
- package/dist/integrationCli-P75R2VSC.js +685 -0
- package/dist/login-SYIQP46J.js +16 -0
- package/dist/{mcpCli-DZWQPTOS.js → mcpCli-QUV5SD64.js} +42 -9
- package/dist/modelsCli-TRRB5LX4.js +36 -0
- package/dist/npmRunner-LU43GM3W.js +46 -0
- package/dist/oauthLogin-6FWQABJ7.js +210 -0
- package/dist/pluginsCli-GNW4TPVV.js +284 -0
- package/dist/prCli-5IMV3VNQ.js +78 -0
- package/dist/providerCli-FAOZHOKW.js +15 -0
- package/dist/sdk.js +5490 -0
- package/dist/serve-6QLBJUYW.js +178 -0
- package/dist/serve-JG7RLIUD.js +515 -0
- package/dist/session-KBAQ4BZ5.js +12 -0
- package/dist/setup-FJAWDWV4.js +24 -0
- package/dist/statsCli-CF3R7ATL.js +353 -0
- package/dist/transferCli-TK2GSVRK.js +71 -0
- package/dist/ui-B3CJ6TGE.js +2365 -0
- package/dist/update-K5IQ2MYR.js +145 -0
- package/package.json +25 -4
- package/dist/args-JPVSGCGY.js +0 -12
- package/dist/chunk-2MGINW4O.js +0 -114
- package/dist/chunk-ISGBGFSU.js +0 -52
- package/dist/chunk-KV27KTOX.js +0 -254
- package/dist/chunk-U7GK73CK.js +0 -341
- package/dist/chunk-ZYCYTEKD.js +0 -96
- package/dist/integrationCli-BGT5UZU4.js +0 -223
- package/dist/login-6K32PIXV.js +0 -9
- package/dist/providerCli-Q7LRM2NP.js +0 -12
- package/dist/session-7UB77CEG.js +0 -9
- package/dist/ui-6GTQUJOE.js +0 -1415
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
t
|
|
4
|
+
} from "./chunk-UZWJQF67.js";
|
|
5
|
+
|
|
6
|
+
// src/completion.ts
|
|
7
|
+
var SHELLS = ["bash", "zsh", "fish", "powershell"];
|
|
8
|
+
function isCompletionShell(value) {
|
|
9
|
+
return SHELLS.includes(value);
|
|
10
|
+
}
|
|
11
|
+
var COMMANDS = [
|
|
12
|
+
"completion",
|
|
13
|
+
"stats",
|
|
14
|
+
"export",
|
|
15
|
+
"import",
|
|
16
|
+
"pr",
|
|
17
|
+
"login",
|
|
18
|
+
"models",
|
|
19
|
+
"update",
|
|
20
|
+
"acp",
|
|
21
|
+
"serve",
|
|
22
|
+
"plugins",
|
|
23
|
+
"gh-bot",
|
|
24
|
+
"provider",
|
|
25
|
+
"mcp",
|
|
26
|
+
"connect",
|
|
27
|
+
"disconnect",
|
|
28
|
+
"integrations"
|
|
29
|
+
];
|
|
30
|
+
var FLAGS = [
|
|
31
|
+
"-p",
|
|
32
|
+
"--print",
|
|
33
|
+
"-m",
|
|
34
|
+
"--model",
|
|
35
|
+
"--reasoning",
|
|
36
|
+
"-c",
|
|
37
|
+
"--continue",
|
|
38
|
+
"-r",
|
|
39
|
+
"--resume",
|
|
40
|
+
"--allow-all",
|
|
41
|
+
"--allowed-tools",
|
|
42
|
+
"-w",
|
|
43
|
+
"--worktree",
|
|
44
|
+
"--output-format",
|
|
45
|
+
"--permission-mode",
|
|
46
|
+
"--lang",
|
|
47
|
+
"-v",
|
|
48
|
+
"--version",
|
|
49
|
+
"-h",
|
|
50
|
+
"--help"
|
|
51
|
+
];
|
|
52
|
+
var WORDS = [...COMMANDS, ...FLAGS].join(" ");
|
|
53
|
+
function bashScript() {
|
|
54
|
+
return `# bccli bash completion \u2014 add to your shell rc:
|
|
55
|
+
# bccli completion bash > ~/.local/share/bash-completion/completions/bccli
|
|
56
|
+
_bccli_complete() {
|
|
57
|
+
local cur
|
|
58
|
+
cur="\${COMP_WORDS[COMP_CWORD]}"
|
|
59
|
+
COMPREPLY=( $(compgen -W "${WORDS}" -- "$cur") )
|
|
60
|
+
}
|
|
61
|
+
complete -F _bccli_complete bccli
|
|
62
|
+
`;
|
|
63
|
+
}
|
|
64
|
+
function zshScript() {
|
|
65
|
+
return `# bccli zsh completion \u2014 add to your shell rc:
|
|
66
|
+
# bccli completion zsh > "\${fpath[1]}/_bccli"
|
|
67
|
+
#compdef bccli
|
|
68
|
+
_bccli() {
|
|
69
|
+
local -a words_list
|
|
70
|
+
words_list=(${WORDS})
|
|
71
|
+
_describe 'command' words_list
|
|
72
|
+
}
|
|
73
|
+
compdef _bccli bccli
|
|
74
|
+
`;
|
|
75
|
+
}
|
|
76
|
+
function fishScript() {
|
|
77
|
+
const lines = [
|
|
78
|
+
"# bccli fish completion \u2014 add to your config:",
|
|
79
|
+
"# bccli completion fish > ~/.config/fish/completions/bccli.fish",
|
|
80
|
+
`# flags: ${FLAGS.join(" ")}`
|
|
81
|
+
];
|
|
82
|
+
for (const w of COMMANDS) lines.push(`complete -c bccli -f -a '${w}'`);
|
|
83
|
+
for (const f of FLAGS) lines.push(`complete -c bccli -l '${f.replace(/^-+/, "")}'`);
|
|
84
|
+
return `${lines.join("\n")}
|
|
85
|
+
`;
|
|
86
|
+
}
|
|
87
|
+
function powershellScript() {
|
|
88
|
+
return `# bccli powershell completion \u2014 add to your profile:
|
|
89
|
+
# bccli completion powershell >> $PROFILE
|
|
90
|
+
Register-ArgumentCompleter -Native -CommandName bccli -ScriptBlock {
|
|
91
|
+
param($wordToComplete, $commandAst, $cursorPosition)
|
|
92
|
+
$words = '${WORDS}' -split ' '
|
|
93
|
+
$words | Where-Object { $_ -like "$wordToComplete*" } | ForEach-Object {
|
|
94
|
+
[System.Management.Automation.CompletionResult]::new($_, $_, 'ParameterValue', $_)
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
`;
|
|
98
|
+
}
|
|
99
|
+
function completionScript(shell) {
|
|
100
|
+
switch (shell) {
|
|
101
|
+
case "bash":
|
|
102
|
+
return bashScript();
|
|
103
|
+
case "zsh":
|
|
104
|
+
return zshScript();
|
|
105
|
+
case "fish":
|
|
106
|
+
return fishScript();
|
|
107
|
+
case "powershell":
|
|
108
|
+
return powershellScript();
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
function runCompletionCommand(args, deps) {
|
|
112
|
+
const shell = (args.subArgs[0] ?? "").trim();
|
|
113
|
+
if (!shell || !isCompletionShell(shell)) {
|
|
114
|
+
deps.err?.(t("usage: bccli completion <{shells}>", { shells: SHELLS.join(", ") }));
|
|
115
|
+
return 1;
|
|
116
|
+
}
|
|
117
|
+
for (const line of completionScript(shell).split("\n")) deps.out(line);
|
|
118
|
+
return 0;
|
|
119
|
+
}
|
|
120
|
+
export {
|
|
121
|
+
SHELLS,
|
|
122
|
+
completionScript,
|
|
123
|
+
isCompletionShell,
|
|
124
|
+
runCompletionCommand
|
|
125
|
+
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
addGlobalServer,
|
|
4
|
+
expandEnvVars,
|
|
4
5
|
globalMcpPath,
|
|
5
6
|
projectMcpPath,
|
|
6
7
|
projectTrust,
|
|
@@ -8,10 +9,12 @@ import {
|
|
|
8
9
|
removeGlobalServer,
|
|
9
10
|
serversToStart,
|
|
10
11
|
setProjectTrust
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-L7QI6JN2.js";
|
|
13
|
+
import "./chunk-LACUWBWS.js";
|
|
14
|
+
import "./chunk-UZWJQF67.js";
|
|
13
15
|
export {
|
|
14
16
|
addGlobalServer,
|
|
17
|
+
expandEnvVars,
|
|
15
18
|
globalMcpPath,
|
|
16
19
|
projectMcpPath,
|
|
17
20
|
projectTrust,
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
ConfigError,
|
|
4
|
+
DEFAULT_MAX_STEPS,
|
|
5
|
+
bccliHome,
|
|
6
|
+
globalConfigPath,
|
|
7
|
+
loadConfig,
|
|
8
|
+
readCredentials,
|
|
9
|
+
readGlobalPlugins,
|
|
10
|
+
readJsonConfig,
|
|
11
|
+
removeCredential,
|
|
12
|
+
resolveModel,
|
|
13
|
+
saveCredential,
|
|
14
|
+
updateGlobalConfig
|
|
15
|
+
} from "./chunk-LACUWBWS.js";
|
|
16
|
+
import "./chunk-UZWJQF67.js";
|
|
17
|
+
export {
|
|
18
|
+
ConfigError,
|
|
19
|
+
DEFAULT_MAX_STEPS,
|
|
20
|
+
bccliHome,
|
|
21
|
+
globalConfigPath,
|
|
22
|
+
loadConfig,
|
|
23
|
+
readCredentials,
|
|
24
|
+
readGlobalPlugins,
|
|
25
|
+
readJsonConfig,
|
|
26
|
+
removeCredential,
|
|
27
|
+
resolveModel,
|
|
28
|
+
saveCredential,
|
|
29
|
+
updateGlobalConfig
|
|
30
|
+
};
|