中文与插件市场
This commit is contained in:
lincube
2026-03-10 12:14:49 +08:00
parent cdffaa16eb
commit 85f7a18cbc
24 changed files with 804 additions and 1443 deletions

View File

@@ -1,34 +1,14 @@
# 插件打包文档
# 插件打包指南
LanMountainDesktop 插件的安装包格式固定为 `.laapp`
## 中文
`LanAirApp/` 负责提供打包标准与打包工具;`.laapp` 的安装、发现和运行时加载由 `LanMountainDesktop/plugins/` 负责。
阑山桌面插件的标准安装格式为 `.laapp`。插件项目应在仓库根目录提供:
## `.laapp` 格式说明
- 本质上是一个标准 zip 压缩包
- 包根目录必须包含 `plugin.json`
- 包根目录还必须包含入口程序集及其依赖
- `.laapp` 安装包
- `README.md`
## 建议打包内容
- `plugin.json`
- `YourPlugin.dll`
- 依赖程序集
- `Localization/zh-CN.json`
- `Localization/en-US.json`
- 插件运行所需的其他资源文件
官方市场索引只负责记录链接和校验信息。
## 使用打包工具
```powershell
dotnet run --project .\LanAirApp\tools\LanMountainDesktop.PluginPackager -- --input .\path\to\plugin-output --output .\artifacts\YourPlugin.laapp --overwrite
```
## English
## 应用内安装流程
1. 打开 `设置 -> 插件`
2. 点击 `打开 .laapp 插件包`
3. 选择要安装的插件包
4. 如果插件注册了设置页或组件,安装后重启应用
## 注意事项
- `plugin.json` 中的 `entranceAssembly` 必须能在包内找到。
- 包内应尽量避免无关开发产物。
- `.laapp` 是标准安装格式,建议不要对外分发散装目录。
The standard package format is `.laapp`. Plugin repositories should keep the package and `README.md` in the repository root, while the official market index stores metadata and validation data.