feat: 开源发布 — 完整 README、MIT 许可证、22+ 大模型厂商支持
- 重写 README.md:项目简介、快速开始、22+ 厂商列表、功能特性、架构说明、配置指南、FAQ、贡献指南 - 新增 MIT LICENSE - 包含全部源码与文档
This commit is contained in:
Regular → Executable
Regular → Executable
Regular → Executable
+13
-1
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env node
|
||||
// Runtime polyfill for bun:bundle (build-time macros)
|
||||
const feature = (_name: string) => false;
|
||||
const feature = (name: string) => name === 'BUDDY';
|
||||
if (typeof globalThis.MACRO === "undefined") {
|
||||
(globalThis as any).MACRO = {
|
||||
VERSION: "2.1.888",
|
||||
@@ -84,8 +84,17 @@ async function main(): Promise<void> {
|
||||
if (args[0] === "--setup" || args[0] === "setup") {
|
||||
const config = await runSetupWizard();
|
||||
applyConfig(config);
|
||||
// Store companion for deferred write after config system is ready
|
||||
if (config.companion) {
|
||||
(globalThis as any).__pendingCompanion = config.companion;
|
||||
}
|
||||
// Remove --setup from args so the CLI doesn't try to parse it
|
||||
args.shift();
|
||||
// Also remove from process.argv so Commander.js doesn't see it
|
||||
const setupIdx = process.argv.indexOf("--setup");
|
||||
if (setupIdx !== -1) process.argv.splice(setupIdx, 1);
|
||||
const setupIdx2 = process.argv.indexOf("setup");
|
||||
if (setupIdx2 !== -1) process.argv.splice(setupIdx2, 1);
|
||||
if (args.length === 0) {
|
||||
// Continue to normal REPL
|
||||
}
|
||||
@@ -93,6 +102,9 @@ async function main(): Promise<void> {
|
||||
// First run, no config, no Anthropic key, interactive mode → show wizard
|
||||
const config = await runSetupWizard();
|
||||
applyConfig(config);
|
||||
if (config.companion) {
|
||||
(globalThis as any).__pendingCompanion = config.companion;
|
||||
}
|
||||
} else if (hasConfig()) {
|
||||
// Load saved config and apply to environment
|
||||
const config = loadConfig();
|
||||
|
||||
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Reference in New Issue
Block a user