From e9c4f1e7d7c3191e6b7040e6c551d41a6819d401 Mon Sep 17 00:00:00 2001 From: OpenAI Codex Date: Wed, 9 Sep 2026 20:59:17 +0800 Subject: [PATCH] chore: configure private npm registry --- packages/maplibre-particle-rn/.npmrc.example | 2 ++ packages/maplibre-particle-rn/README.md | 22 ++++++++++++++++++++ packages/maplibre-particle-rn/package.json | 3 +++ 3 files changed, 27 insertions(+) create mode 100644 packages/maplibre-particle-rn/.npmrc.example diff --git a/packages/maplibre-particle-rn/.npmrc.example b/packages/maplibre-particle-rn/.npmrc.example new file mode 100644 index 000000000..c4b54b5ca --- /dev/null +++ b/packages/maplibre-particle-rn/.npmrc.example @@ -0,0 +1,2 @@ +@navsea:registry=https://git.eyaku.jp/api/packages/tei/npm/ +//git.eyaku.jp/api/packages/tei/npm/:_authToken=${GITEA_NPM_TOKEN} diff --git a/packages/maplibre-particle-rn/README.md b/packages/maplibre-particle-rn/README.md index 99d9d215e..55275ac39 100644 --- a/packages/maplibre-particle-rn/README.md +++ b/packages/maplibre-particle-rn/README.md @@ -6,6 +6,28 @@ Android 使用 `cc.navsea.maplibre:android-sdk-particle-opengl:13.4.1-particle.1 WeatherColor 和 RasterParticle 是 Core-only style layer,不是 React 组件。使用 `createParticleWeatherStyle()` 或等价 Style JSON 声明。binary submit 始终为 `metadataJson + local file:// payload`,通过 `WeatherRuntime.submitWindField()` 进入既有 Native/Core 链路。 + +## 私有 npm Registry 安装 + +本包正式 Registry 固定为 Gitea:`https://git.eyaku.jp/api/packages/tei/npm/`。Consumer 项目不要依赖 MapLibreParticleLab 源码路径,也不要长期使用手工复制的 tgz。 + +Consumer 项目根目录 `.npmrc`: + +```ini +@navsea:registry=https://git.eyaku.jp/api/packages/tei/npm/ +//git.eyaku.jp/api/packages/tei/npm/:_authToken=${GITEA_NPM_TOKEN} +``` + +然后锁定版本安装: + +```bash +npm install @navsea/maplibre-particle-rn@13.4.1-particle.1 @maplibre/maplibre-react-native@11.3.6 +``` + +`GITEA_NPM_TOKEN` 由宿主环境、CI 或开发机安全注入,不提交到 Git。读取私有包使用 Package 读取权限;发布使用 Package 写入权限。 + +本包 `package.json` 的 `publishConfig.registry` 已固定到上述 Gitea Registry,因此发布端在认证完成后从本目录执行 `npm publish` 即可,不应临时切换到 npmjs.org。已发布版本不得覆盖;任何修改发布为新的 `13.4.1-particle.N`。 + ## WeatherV2 HTTP 数据链 包内 `weatherV2` 子模块负责: diff --git a/packages/maplibre-particle-rn/package.json b/packages/maplibre-particle-rn/package.json index 29329ce7e..e2244c958 100644 --- a/packages/maplibre-particle-rn/package.json +++ b/packages/maplibre-particle-rn/package.json @@ -46,5 +46,8 @@ }, "devDependencies": { "@maplibre/maplibre-react-native": "11.3.6" + }, + "publishConfig": { + "registry": "https://git.eyaku.jp/api/packages/tei/npm/" } }