diff --git a/.vscode/launch.json b/.vscode/launch.json index a024fc6..c03d25f 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -2,7 +2,7 @@ "version": "0.2.0", "configurations": [ { - "name": "FutureOSS: 启动服务", + "name": "NebulaShell: 启动服务", "type": "python", "request": "launch", "module": "oss.cli", @@ -17,7 +17,7 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试模式启动", + "name": "NebulaShell: 调试模式启动", "type": "python", "request": "launch", "module": "oss.cli", @@ -33,7 +33,7 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 运行测试", + "name": "NebulaShell: 运行测试", "type": "python", "request": "launch", "module": "pytest", @@ -53,7 +53,7 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试插件加载器", + "name": "NebulaShell: 调试插件加载器", "type": "python", "request": "launch", "program": "${workspaceFolder}/oss/plugin/loader.py", @@ -67,10 +67,10 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试日志终端插件", + "name": "NebulaShell: 调试日志终端插件", "type": "python", "request": "launch", - "program": "${workspaceFolder}/store/@{FutureOSS}/log-terminal/main.py", + "program": "${workspaceFolder}/store/@{NebulaShell}/log-terminal/main.py", "console": "integratedTerminal", "justMyCode": false, "env": { @@ -81,10 +81,10 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试WebUI", + "name": "NebulaShell: 调试WebUI", "type": "python", "request": "launch", - "program": "${workspaceFolder}/store/@{FutureOSS}/webui/main.py", + "program": "${workspaceFolder}/store/@{NebulaShell}/webui/main.py", "console": "integratedTerminal", "justMyCode": false, "env": { @@ -95,10 +95,10 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试HTTP API", + "name": "NebulaShell: 调试HTTP API", "type": "python", "request": "launch", - "program": "${workspaceFolder}/store/@{FutureOSS}/http-api/main.py", + "program": "${workspaceFolder}/store/@{NebulaShell}/http-api/main.py", "console": "integratedTerminal", "justMyCode": false, "env": { @@ -109,10 +109,10 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试WS API", + "name": "NebulaShell: 调试WS API", "type": "python", "request": "launch", - "program": "${workspaceFolder}/store/@{FutureOSS}/ws-api/main.py", + "program": "${workspaceFolder}/store/@{NebulaShell}/ws-api/main.py", "console": "integratedTerminal", "justMyCode": false, "env": { @@ -123,7 +123,7 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 调试特定文件", + "name": "NebulaShell: 调试特定文件", "type": "python", "request": "launch", "program": "${file}", @@ -137,7 +137,7 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS: 附加到进程", + "name": "NebulaShell: 附加到进程", "type": "python", "request": "attach", "processId": "${command:pickProcess}", @@ -152,7 +152,7 @@ "justMyCode": false }, { - "name": "FutureOSS: 运行CLI命令", + "name": "NebulaShell: 运行CLI命令", "type": "python", "request": "launch", "module": "oss.cli", @@ -167,7 +167,7 @@ "python": "${command:python.interpreterPath}" }, { - "name": "FutureOSS 网站: 启动Node.js服务器", + "name": "NebulaShell 网站: 启动Node.js服务器", "type": "node", "request": "launch", "skipFiles": [ @@ -190,7 +190,7 @@ "cwd": "${workspaceFolder}/website" }, { - "name": "FutureOSS 网站: 开发模式启动", + "name": "NebulaShell 网站: 开发模式启动", "type": "node", "request": "launch", "skipFiles": [ @@ -208,7 +208,7 @@ "cwd": "${workspaceFolder}/website" }, { - "name": "FutureOSS 网站: 附加到Node.js进程", + "name": "NebulaShell 网站: 附加到Node.js进程", "type": "node", "request": "attach", "port": 9229, @@ -230,10 +230,10 @@ ], "compounds": [ { - "name": "FutureOSS: 完整调试环境", + "name": "NebulaShell: 完整调试环境", "configurations": [ - "FutureOSS: 启动服务", - "FutureOSS: 调试日志终端插件" + "NebulaShell: 启动服务", + "NebulaShell: 调试日志终端插件" ], "stopAll": true } diff --git a/.vscode/settings.json b/.vscode/settings.json index 2b59acc..5de87fa 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -5,7 +5,7 @@ "python.analysis.extraPaths": [ "${workspaceFolder}", "${workspaceFolder}/oss", - "${workspaceFolder}/store/@{FutureOSS}" + "${workspaceFolder}/store/@{NebulaShell}" ], "python.analysis.typeCheckingMode": "basic", "python.analysis.autoImportCompletions": true, diff --git a/.vscode/tasks.json b/.vscode/tasks.json index fac1aca..bf06948 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -2,7 +2,7 @@ "version": "2.0.0", "tasks": [ { - "label": "FutureOSS: 安装依赖", + "label": "NebulaShell: 安装依赖", "type": "shell", "command": "pip install -r requirements.txt", "group": { @@ -23,7 +23,7 @@ } }, { - "label": "FutureOSS: 启动开发服务器", + "label": "NebulaShell: 启动开发服务器", "type": "shell", "command": "python -m oss.cli serve", "group": "none", @@ -48,7 +48,7 @@ ], "background": { "activeOnStart": true, - "beginsPattern": ".*启动 FutureOSS 服务.*", + "beginsPattern": ".*启动 NebulaShell 服务.*", "endsPattern": ".*服务已启动.*" } } @@ -58,7 +58,7 @@ } }, { - "label": "FutureOSS: 运行测试", + "label": "NebulaShell: 运行测试", "type": "shell", "command": "pytest -v --tb=short", "group": "test", @@ -89,9 +89,9 @@ } }, { - "label": "FutureOSS: 代码检查", + "label": "NebulaShell: 代码检查", "type": "shell", - "command": "python -m pylint oss/ store/@{FutureOSS}/ --rcfile=${workspaceFolder}/.pylintrc || echo 'Pylint检查完成'", + "command": "python -m pylint oss/ store/@{NebulaShell}/ --rcfile=${workspaceFolder}/.pylintrc || echo 'Pylint检查完成'", "group": "build", "presentation": { "echo": true, @@ -122,9 +122,9 @@ } }, { - "label": "FutureOSS: 格式化代码", + "label": "NebulaShell: 格式化代码", "type": "shell", - "command": "python -m black oss/ store/@{FutureOSS}/", + "command": "python -m black oss/ store/@{NebulaShell}/", "group": "build", "presentation": { "echo": true, @@ -140,7 +140,7 @@ } }, { - "label": "FutureOSS: 清理缓存文件", + "label": "NebulaShell: 清理缓存文件", "type": "shell", "command": "find . -type f -name '*.pyc' -delete && find . -type d -name '__pycache__' -delete && find . -type f -name '.pid' -delete", "group": "build", @@ -158,7 +158,7 @@ } }, { - "label": "FutureOSS: 查看服务状态", + "label": "NebulaShell: 查看服务状态", "type": "shell", "command": "if [ -f .pid ]; then echo '服务正在运行,PID: ' && cat .pid; else echo '服务未运行'; fi", "group": "none", @@ -176,7 +176,7 @@ } }, { - "label": "FutureOSS: 停止服务", + "label": "NebulaShell: 停止服务", "type": "shell", "command": "if [ -f .pid ]; then kill $(cat .pid) && rm -f .pid && echo '服务已停止'; else echo '服务未运行'; fi", "group": "none", @@ -194,12 +194,12 @@ } }, { - "label": "FutureOSS: 重启服务", + "label": "NebulaShell: 重启服务", "type": "shell", "dependsOrder": "sequence", "dependsOn": [ - "FutureOSS: 停止服务", - "FutureOSS: 启动开发服务器" + "NebulaShell: 停止服务", + "NebulaShell: 启动开发服务器" ], "group": "none", "presentation": { diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..c776234 --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,66 @@ +# AGENTS.md — NebulaShell + +## Quick start + +```bash +pip install -r requirements.txt +python -m oss.cli serve # start server on :8080 +# or: python main.py +# or: oss serve (after pip install -e .) +``` + +## Architecture (minimal core philosophy) + +- Core framework (`oss/`) loads only **one** builtin plugin: `store/@{NebulaShell}/plugin-loader/` +- `plugin-loader` then scans `store/@{NebulaShell}/` and manages all other plugins +- Two store namespaces: `@{NebulaShell}` (26 official plugins) and `@{Falck}` (2 plugins) +- Entry point: `oss/cli.py:main()` → `PluginManager` → `PluginLoader.load_core_plugin("plugin-loader")` +- Each store plugin at `store/@{NebulaShell}//main.py` must export a `New()` factory function +- Plugin base class: `oss/plugin/types.py:Plugin` (abstract: `init`, `start`, `stop`) + +## Commands + +| Action | Command | +|--------|---------| +| Start server | `python -m oss.cli serve` | +| Show info | `python -m oss.cli info` | +| Hidden achievements | Prefix with `!!` (e.g., `!!help`, `!!list`, `!!stats`, `!!debug`) | +| Docker | `docker-compose up` (ports 8080-8082) | + +Hidden commands defined in `oss/core/achievements.py` — they are a gamification layer, not real administration. + +## Config + +- **`oss.config.json`** — runtime config (port, host, data/store dirs, log level, permissions) +- Priority: env var > `oss.config.json` > hardcoded defaults (`oss/config/config.py`) +- Must set `PYTHONPATH` to repo root before running anything +- `PYTHONUNBUFFERED=1` recommended for dev + +## Test + +```bash +pytest -v --tb=short # single test file: oss/tests/test_nodejs_adapter.py +``` + +Tests require Node.js/npm on `$PATH` or many tests skip. No CI workflows exist. + +## Toolchain + +``` +black oss/ store/@{NebulaShell}/ # formatter (line-length=88) +pylint oss/ store/@{NebulaShell}/ # linter (references .pylintrc, file may not exist) +``` + +No typechecker configured. No CI. + +## Rename history + +This project was renamed from **FutureOSS** → **NebulaShell**. Old name may still appear in git history, external URLs, or stale wiki references. Always use "NebulaShell" in new code. + +## Ports + +| Port | Service | +|------|---------| +| 8080 | HTTP API + WebUI | +| 8081 | WebSocket | +| 8082 | HTTP TCP | diff --git a/Dockerfile b/Dockerfile index 4096e44..50a7658 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,7 +17,7 @@ RUN pip install --no-cache-dir --prefix=/install click pyyaml websockets 2>/dev/ FROM python:3.12-slim LABEL maintainer="Falck " -LABEL description="FutureOSS — 一切皆为插件的开发者工具运行时框架" +LABEL description="NebulaShell — 一切皆为插件的开发者工具运行时框架" WORKDIR /app diff --git a/README.md b/README.md index 0a2b42a..420fed7 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# 🚀 FutureOSS v1.2.0 企业级插件化运行时框架 +# 🚀 NebulaShell v1.2.0 企业级插件化运行时框架
@@ -25,7 +25,7 @@ > ### 🌟 **革命性突破 - 彻底告别依赖安装烦恼!** > -> 想象一下:只需声明你的插件需要什么,剩下的交给 FutureOSS! +> 想象一下:只需声明你的插件需要什么,剩下的交给 NebulaShell! > > | 🚀 核心能力 | 💡 技术亮点 | > |:----------:|:-----------| @@ -38,7 +38,7 @@ --- -## 🚀 为什么选择 FutureOSS? +## 🚀 为什么选择 NebulaShell?
🛡️ 极致安全架构 - 重新定义插件安全边界 (点击展开) @@ -215,7 +215,7 @@ %%{init: {'theme': 'base', 'themeVariables': { 'primaryColor': '#667eea', 'edgeLabelBackground':'#fff', 'tertiaryColor': '#e3f2fd'}}}%% graph TB User[👤 用户/客户端] --> Gateway[🛡️ 统一安全网关] - Gateway --> Core[⚙️ FutureOSS 微内核] + Gateway --> Core[⚙️ NebulaShell 微内核] subgraph CoreLayer["🔐 核心插件层 (可信域)"] direction TB @@ -289,7 +289,7 @@ graph TB "author": "Your Name ", "license": "MIT", - // 🔥 系统依赖声明(FutureOSS 自动安装) + // 🔥 系统依赖声明(NebulaShell 自动安装) "system_dependencies": [ "nginx", "redis-server", @@ -301,7 +301,7 @@ graph TB // 📦 包管理器选择 "package_manager": "apt-get", - // 🔌 插件依赖(其他 FutureOSS 插件) + // 🔌 插件依赖(其他 NebulaShell 插件) "plugin_dependencies": [ "security_gateway@>=1.0.0", "firewall@>=1.0.0" @@ -387,13 +387,13 @@ xcode-select --install # 安装 Xcode 命令行工具 ```bash # 📥 克隆仓库 -git clone https://github.com/Starlight-apk/FutureOSS.git -cd futureoss +git clone https://github.com/Starlight-apk/NebulaShell.git +cd nebulashell # 📦 安装 Python 依赖 pip install -r requirements.txt -# 🚀 启动 FutureOSS 核心 +# 🚀 启动 NebulaShell 核心 python main.py # 🎉 完成!观察控制台输出 @@ -533,8 +533,8 @@ graph LR ```bash # 1️⃣ Fork 你的专属仓库 -git clone https://github.com/Starlight-apk/FutureOSS.git -cd futureoss +git clone https://github.com/Starlight-apk/NebulaShell.git +cd nebulashell # 2️⃣ 创建虚拟环境 python -m venv venv @@ -776,21 +776,21 @@ git push origin feature/your-amazing-feature ### 如果这个项目帮助到了你,请给我们一个 ⭐ Star! -[![Star on GitHub](https://img.shields.io/github/stars/Starlight-apk/FutureOSS?style=social&logo=github)](https://github.com/Starlight-apk/FutureOSS) -[![Fork on GitHub](https://img.shields.io/github/forks/Starlight-apk/FutureOSS?style=social&logo=github)](https://github.com/Starlight-apk/FutureOSS/fork) -[![Watch on GitHub](https://img.shields.io/github/watchers/Starlight-apk/FutureOSS?style=social&logo=github)](https://github.com/Starlight-apk/FutureOSS/watchers) +[![Star on GitHub](https://img.shields.io/github/stars/Starlight-apk/NebulaShell?style=social&logo=github)](https://github.com/Starlight-apk/NebulaShell) +[![Fork on GitHub](https://img.shields.io/github/forks/Starlight-apk/NebulaShell?style=social&logo=github)](https://github.com/Starlight-apk/NebulaShell/fork) +[![Watch on GitHub](https://img.shields.io/github/watchers/Starlight-apk/NebulaShell?style=social&logo=github)](https://github.com/Starlight-apk/NebulaShell/watchers) --- ### 👥 致谢所有贡献者 - - Contributors + + Contributors --- -*🚀 **Built with ❤️ by [FutureOSS Team](https://github.com/Starlight-apk)** * +*🚀 **Built with ❤️ by [NebulaShell Team](https://github.com/Starlight-apk)** * *✨ **面向未来,安全随行 - 让插件开发从未如此简单** * *🌍 **Made possible by our amazing community** * @@ -798,7 +798,7 @@ git push origin feature/your-amazing-feature
-[🏠 官网首页](https://futureoss.date) +[🏠 官网首页](https://nebulashell.date)
diff --git a/RELEASE_v1.1.0.md b/RELEASE_v1.1.0.md index cb8f5bc..5a0d9e5 100644 --- a/RELEASE_v1.1.0.md +++ b/RELEASE_v1.1.0.md @@ -1,4 +1,4 @@ -# 🚀 FutureOSS v1.1.0 安全全能发行版 - 发布说明 +# 🚀 NebulaShell v1.1.0 安全全能发行版 - 发布说明 ## 📅 发布时间 2024 年 4 月 24 日 @@ -137,9 +137,9 @@ firewall.ip.block reason= ## 📞 技术支持 -- 文档:https://futureoss.org/docs/v1.1.0 +- 文档:https://nebulashell.org/docs/v1.1.0 - 问题反馈:GitHub Issues - 社区讨论:Discord / Slack --- -**FutureOSS Team** © 2024 | 安全 · 灵活 · 高效 +**NebulaShell Team** © 2024 | 安全 · 灵活 · 高效 diff --git a/docker-compose.yml b/docker-compose.yml index 99825a4..7ef1fb4 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,9 +1,9 @@ services: - futureoss: + nebulashell: build: context: . dockerfile: Dockerfile - container_name: futureoss + container_name: nebulashell restart: unless-stopped ports: - "8080:8080" # HTTP API + 网站 @@ -11,10 +11,10 @@ services: - "8082:8082" # HTTP TCP volumes: # 插件热更新(无需重建镜像) - - ./store/@{FutureOSS}:/app/store/@{FutureOSS}:ro + - ./store/@{NebulaShell}:/app/store/@{NebulaShell}:ro - ./store/@{Falck}:/app/store/@{Falck}:ro # 数据持久化 - - futureoss-data:/app/data + - nebulashell-data:/app/data # 配置可覆盖 - ./config.yaml:/app/config.yaml:ro environment: @@ -39,5 +39,5 @@ services: memory: 128M volumes: - futureoss-data: + nebulashell-data: driver: local diff --git a/future_oss.egg-info/PKG-INFO b/future_oss.egg-info/PKG-INFO deleted file mode 100644 index 979fd61..0000000 --- a/future_oss.egg-info/PKG-INFO +++ /dev/null @@ -1,10 +0,0 @@ -Metadata-Version: 2.4 -Name: future-oss -Version: 1.2.0 -Summary: Future OSS - 一切皆为插件的开发者工具运行时框架 -Requires-Python: >=3.10 -License-File: LICENSE -Requires-Dist: click>=8.0 -Requires-Dist: pyyaml>=6.0 -Requires-Dist: websockets>=12.0 -Dynamic: license-file diff --git a/future_oss.egg-info/SOURCES.txt b/future_oss.egg-info/SOURCES.txt deleted file mode 100644 index 4920d70..0000000 --- a/future_oss.egg-info/SOURCES.txt +++ /dev/null @@ -1,27 +0,0 @@ -LICENSE -README.md -pyproject.toml -future_oss.egg-info/PKG-INFO -future_oss.egg-info/SOURCES.txt -future_oss.egg-info/dependency_links.txt -future_oss.egg-info/entry_points.txt -future_oss.egg-info/requires.txt -future_oss.egg-info/top_level.txt -oss/__init__.py -oss/cli.py -oss/core/context.py -oss/logger/logger.py -oss/plugin/base.py -oss/plugin/capabilities.py -oss/plugin/loader.py -oss/plugin/manager.py -oss/plugin/types.py -oss/plugins/auto_dependency.py -oss/plugins/firewall.py -oss/plugins/frp_proxy.py -oss/plugins/ftp_server.py -oss/plugins/multi_lang_deploy.py -oss/plugins/ops_toolbox.py -oss/plugins/security_gateway.py -oss/shared/__init__.py -oss/shared/router.py \ No newline at end of file diff --git a/future_oss.egg-info/dependency_links.txt b/future_oss.egg-info/dependency_links.txt deleted file mode 100644 index 8b13789..0000000 --- a/future_oss.egg-info/dependency_links.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/future_oss.egg-info/entry_points.txt b/future_oss.egg-info/entry_points.txt deleted file mode 100644 index 35dec38..0000000 --- a/future_oss.egg-info/entry_points.txt +++ /dev/null @@ -1,2 +0,0 @@ -[console_scripts] -oss = oss.cli:main diff --git a/future_oss.egg-info/requires.txt b/future_oss.egg-info/requires.txt deleted file mode 100644 index 552ae57..0000000 --- a/future_oss.egg-info/requires.txt +++ /dev/null @@ -1,3 +0,0 @@ -click>=8.0 -pyyaml>=6.0 -websockets>=12.0 diff --git a/future_oss.egg-info/top_level.txt b/future_oss.egg-info/top_level.txt deleted file mode 100644 index 62ab099..0000000 --- a/future_oss.egg-info/top_level.txt +++ /dev/null @@ -1 +0,0 @@ -oss diff --git a/main.py b/main.py index 19452f2..6b3f2c8 100644 --- a/main.py +++ b/main.py @@ -1,5 +1,5 @@ #!/usr/bin/env python3 -"""FutureOSS 主入口 - 兼容旧版启动方式 +"""NebulaShell 主入口 - 兼容旧版启动方式 此文件用于兼容 README 中描述的 `python main.py` 启动方式。 推荐使用 `oss serve` 命令启动。 diff --git a/oss/__init__.py b/oss/__init__.py index 9af8bc3..d33741d 100644 --- a/oss/__init__.py +++ b/oss/__init__.py @@ -1,2 +1,2 @@ -"""Future OSS""" +"""NebulaShell""" __version__ = "1.2.0" diff --git a/oss/cli.py b/oss/cli.py index 1a89758..6ded060 100644 --- a/oss/cli.py +++ b/oss/cli.py @@ -22,7 +22,7 @@ except ImportError: @click.option('--config', '-c', type=str, help='配置文件路径') @click.pass_context def cli(ctx, config): - """Future OSS - 一切皆为插件""" + """NebulaShell - 一切皆为插件""" # 初始化配置 ctx.ensure_object(dict) ctx.obj['config'] = init_config(config) @@ -41,7 +41,7 @@ def cli(ctx, config): @click.option('--tcp-port', type=int, default=None, help='HTTP TCP 端口') @click.pass_context def serve(ctx, host, port, tcp_port): - """启动 Future OSS""" + """启动 NebulaShell""" config = ctx.obj.get('config', get_config()) # 命令行参数覆盖配置 @@ -53,7 +53,7 @@ def serve(ctx, host, port, tcp_port): config.set('HTTP_TCP_PORT', tcp_port) log = Logger() - log.info(f"Future OSS {__version__} 启动") + log.info(f"NebulaShell {__version__} 启动") log.info(f"监听地址:{config.host}:{config.http_api_port}") log.info(f"数据目录:{config.data_dir.absolute()}") log.info(f"插件仓库:{config.store_dir.absolute()}") @@ -84,7 +84,7 @@ def serve(ctx, host, port, tcp_port): @cli.command() def version(): """显示版本""" - click.echo(f"Future OSS {__version__}") + click.echo(f"NebulaShell {__version__}") @cli.command() @@ -94,7 +94,7 @@ def info(ctx): import random config = ctx.obj.get('config', get_config()) - click.echo(f"Future OSS {__version__}") + click.echo(f"NebulaShell {__version__}") click.echo(f"配置文件:{config._config_file or '无'}") click.echo(f"HTTP API 端口:{config.http_api_port}") click.echo(f"HTTP TCP 端口:{config.http_tcp_port}") diff --git a/oss/core/achievements.py b/oss/core/achievements.py index 9d623fd..299548e 100644 --- a/oss/core/achievements.py +++ b/oss/core/achievements.py @@ -17,8 +17,8 @@ from typing import Dict, List, Optional, Set, Any # 配置验证常量 _VALIDATOR_CACHE_FILE = ".validator_cache" -# 验证密钥 (hex encoded): FutureOSSAchievement -_VALIDATOR_KEY = "4675747572654f5353416368696576656d656e74" # 验证密钥 +# 验证密钥 (hex encoded): NebulaShellAchievement +_VALIDATOR_KEY = "4e6562756c615368656c6c416368696576656d656e74" # 验证密钥 class _ConfigValidator: diff --git a/oss/plugin/loader.py b/oss/plugin/loader.py index 587bec6..732fdb9 100644 --- a/oss/plugin/loader.py +++ b/oss/plugin/loader.py @@ -1,7 +1,7 @@ """插件加载器 - 专门用于加载核心插件 遵循「最小化核心框架」设计哲学: -- 只负责加载可信的核心插件(来自 store/@{FutureOSS}/) +- 只负责加载可信的核心插件(来自 store/@{NebulaShell}/) - 所有插件都使用统一的加载机制 - 不再区分沙箱模式和非沙箱模式 """ @@ -17,7 +17,7 @@ class PluginLoader: """插件加载器 - 专门用于加载核心插件 遵循「最小化核心框架」设计哲学: - - 只负责加载可信的核心插件(来自 store/@{FutureOSS}/) + - 只负责加载可信的核心插件(来自 store/@{NebulaShell}/) - 所有插件都使用统一的加载机制 - 不再区分沙箱模式和非沙箱模式 """ @@ -27,7 +27,7 @@ class PluginLoader: self._config = get_config() def load_core_plugin(self, plugin_name: str, store_dir: Optional[str] = None) -> Optional[dict[str, Any]]: - """加载核心插件(来自 store/@{FutureOSS}/) + """加载核心插件(来自 store/@{NebulaShell}/) Args: plugin_name: 插件名称(如 "plugin-loader") @@ -38,7 +38,7 @@ class PluginLoader: """ if store_dir is None: store_dir = str(self._config.store_dir) - plugin_dir = Path(store_dir) / "@{FutureOSS}" / plugin_name + plugin_dir = Path(store_dir) / "@{NebulaShell}" / plugin_name return self._load_plugin(plugin_name, plugin_dir) def _load_plugin(self, plugin_name: str, plugin_dir: Path) -> Optional[dict[str, Any]]: diff --git a/oss/plugin/manager.py b/oss/plugin/manager.py index ae9fb6a..58ad86a 100644 --- a/oss/plugin/manager.py +++ b/oss/plugin/manager.py @@ -17,7 +17,7 @@ class PluginManager: 遵循「最小化核心框架」设计哲学: - 核心框架只负责加载 plugin-loader 插件 - 所有其他插件(HTTP、WebSocket、Dashboard 等)都由 plugin-loader 插件扫描和加载 - - store/@{FutureOSS}/ 是唯一的插件来源 + - store/@{NebulaShell}/ 是唯一的插件来源 """ def __init__(self): @@ -28,7 +28,7 @@ class PluginManager: """仅加载 plugin-loader 核心插件 plugin-loader 插件会负责: - 1. 扫描 store/@{FutureOSS}/ 目录 + 1. 扫描 store/@{NebulaShell}/ 目录 2. 加载所有启用的插件 3. 处理依赖关系 4. 执行 PL 注入机制 diff --git a/oss/store/@{FutureOSS}/nodejs-adapter/README.md b/oss/store/@{NebulaShell}/nodejs-adapter/README.md similarity index 97% rename from oss/store/@{FutureOSS}/nodejs-adapter/README.md rename to oss/store/@{NebulaShell}/nodejs-adapter/README.md index f895e0e..dcdeaae 100644 --- a/oss/store/@{FutureOSS}/nodejs-adapter/README.md +++ b/oss/store/@{NebulaShell}/nodejs-adapter/README.md @@ -1,4 +1,4 @@ -# @FutureOSS/nodejs-adapter +# @NebulaShell/nodejs-adapter **Pure Node.js Runtime Adapter Service** @@ -33,7 +33,7 @@ In your plugin's `manifest.json`: { "name": "@MyOrg/my-web-plugin", "dependencies": { - "adapters": ["@FutureOSS/nodejs-adapter"] + "adapters": ["@NebulaShell/nodejs-adapter"] } } ``` diff --git a/oss/store/@{FutureOSS}/nodejs-adapter/main.py b/oss/store/@{NebulaShell}/nodejs-adapter/main.py similarity index 99% rename from oss/store/@{FutureOSS}/nodejs-adapter/main.py rename to oss/store/@{NebulaShell}/nodejs-adapter/main.py index 8ced973..f4a1cb9 100644 --- a/oss/store/@{FutureOSS}/nodejs-adapter/main.py +++ b/oss/store/@{NebulaShell}/nodejs-adapter/main.py @@ -1,5 +1,5 @@ """ -Node.js Runtime Adapter for FutureOSS +Node.js Runtime Adapter for NebulaShell ===================================== This plugin acts as a pure service provider (Adapter). It does NOT contain its own business logic or pkg. Instead, it exposes standard interfaces for OTHER plugins to execute Node.js/npm commands diff --git a/oss/store/@{FutureOSS}/nodejs-adapter/manifest.json b/oss/store/@{NebulaShell}/nodejs-adapter/manifest.json similarity index 89% rename from oss/store/@{FutureOSS}/nodejs-adapter/manifest.json rename to oss/store/@{NebulaShell}/nodejs-adapter/manifest.json index 4cd39d9..93bfe89 100644 --- a/oss/store/@{FutureOSS}/nodejs-adapter/manifest.json +++ b/oss/store/@{NebulaShell}/nodejs-adapter/manifest.json @@ -1,8 +1,8 @@ { - "name": "@FutureOSS/nodejs-adapter", + "name": "@NebulaShell/nodejs-adapter", "version": "1.0.0", "description": "Pure Node.js runtime adapter service. Provides execution context for other plugins to run Node.js/npm commands in their own ./pkg directories.", - "author": "FutureOSS Team", + "author": "NebulaShell Team", "license": "MIT", "type": "adapter", "main": "main.py", diff --git a/oss/tests/test_nodejs_adapter.py b/oss/tests/test_nodejs_adapter.py index 3c8f18e..4cae325 100644 --- a/oss/tests/test_nodejs_adapter.py +++ b/oss/tests/test_nodejs_adapter.py @@ -10,7 +10,7 @@ import shutil import pytest # Add the plugin directory to path -PLUGIN_DIR = os.path.join(os.path.dirname(__file__), '..', 'store', '@{FutureOSS}', 'nodejs-adapter') +PLUGIN_DIR = os.path.join(os.path.dirname(__file__), '..', 'store', '@{NebulaShell}', 'nodejs-adapter') sys.path.insert(0, PLUGIN_DIR) # Import after path update diff --git a/oss/webui/index.html b/oss/webui/index.html index 2195539..846f0ed 100644 --- a/oss/webui/index.html +++ b/oss/webui/index.html @@ -3,7 +3,7 @@ - FutureOSS v1.1.0 | 控制台 + NebulaShell v1.1.0 | 控制台