更改项目名为NebulaShell
This commit is contained in:
@@ -1,2 +1,2 @@
|
||||
"""Future OSS"""
|
||||
"""NebulaShell"""
|
||||
__version__ = "1.2.0"
|
||||
|
||||
10
oss/cli.py
10
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}")
|
||||
|
||||
@@ -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:
|
||||
|
||||
@@ -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]]:
|
||||
|
||||
@@ -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 注入机制
|
||||
|
||||
@@ -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"]
|
||||
}
|
||||
}
|
||||
```
|
||||
@@ -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
|
||||
@@ -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",
|
||||
@@ -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
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>FutureOSS v1.1.0 | 控制台</title>
|
||||
<title>NebulaShell v1.1.0 | 控制台</title>
|
||||
<style>
|
||||
:root {
|
||||
--bg: #ffffff;
|
||||
@@ -146,7 +146,7 @@
|
||||
<body>
|
||||
<div class="container">
|
||||
<header>
|
||||
<h1>FutureOSS</h1>
|
||||
<h1>NebulaShell</h1>
|
||||
<p class="subtitle">v1.1.0 安全全能发行版 · 企业级插件化运行时</p>
|
||||
</header>
|
||||
|
||||
@@ -204,7 +204,7 @@
|
||||
</div>
|
||||
|
||||
<footer>
|
||||
<p>FutureOSS v1.1.0 Security All-in-One Edition</p>
|
||||
<p>NebulaShell v1.1.0 Security All-in-One Edition</p>
|
||||
<p style="margin-top: 8px;">Built with ❤️ · MIT License</p>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user