Merge pull request #44 from modelstudioai/fix/auto-check-version

feat: Change the version in SKILL to an optional verification
This commit is contained in:
Gong Shiqi
2026-06-10 17:05:47 +08:00
committed by GitHub
4 changed files with 37 additions and 20 deletions
+7 -7
View File
@@ -171,14 +171,14 @@ Config file location: `~/.bailian/config.json`
## Links
| Resource | URL |
| :--------------------------- | :---------------------------------------------------------------- |
| Aliyun Model Studio CLI Site | https://bailian.console.aliyun.com/cli?source_channel=cli_github& |
| DashScope API Docs | https://help.aliyun.com/zh/model-studio/ |
| Qwen Model List | https://help.aliyun.com/zh/model-studio/getting-started/models |
| Aliyun Model Studio Console | https://bailian.console.aliyun.com/?source_channel=cli_github |
| Resource | URL |
| :--------------------------- | :---------------------------------------------------------------------------------------- |
| Aliyun Model Studio CLI Site | https://bailian.console.aliyun.com/cli?source_channel=cli_github& |
| DashScope API Docs | https://help.aliyun.com/zh/model-studio/ |
| Qwen Model List | https://help.aliyun.com/zh/model-studio/getting-started/models |
| Aliyun Model Studio Console | https://bailian.console.aliyun.com/?source_channel=cli_github |
| Get API Key | https://bailian.console.aliyun.com/cn-beijing/?source_channel=key_github&tab=app#/api-key |
| Get AccessKey | https://ram.console.aliyun.com/manage/ak |
| Get AccessKey | https://ram.console.aliyun.com/manage/ak |
## Changelog
+7 -7
View File
@@ -166,14 +166,14 @@ bl update
## 相关链接
| 资源 | 地址 |
| :---------------------- | :---------------------------------------------------------------- |
| 阿里云百炼 CLI 官方主页 | https://bailian.console.aliyun.com/cli?source_channel=cli_github& |
| DashScope API 文档 | https://help.aliyun.com/zh/model-studio/ |
| 通义千问模型列表 | https://help.aliyun.com/zh/model-studio/getting-started/models |
| 阿里云百炼控制台 | https://bailian.console.aliyun.com/?source_channel=cli_github |
| 资源 | 地址 |
| :---------------------- | :---------------------------------------------------------------------------------------- |
| 阿里云百炼 CLI 官方主页 | https://bailian.console.aliyun.com/cli?source_channel=cli_github& |
| DashScope API 文档 | https://help.aliyun.com/zh/model-studio/ |
| 通义千问模型列表 | https://help.aliyun.com/zh/model-studio/getting-started/models |
| 阿里云百炼控制台 | https://bailian.console.aliyun.com/?source_channel=cli_github |
| 获取 API Key | https://bailian.console.aliyun.com/cn-beijing/?source_channel=key_github&tab=app#/api-key |
| 获取 AccessKey | https://ram.console.aliyun.com/manage/ak |
| 获取 AccessKey | https://ram.console.aliyun.com/manage/ak |
## 更新日志
+22 -5
View File
@@ -16,8 +16,15 @@ function step(msg) {
/**
* Pure-validation pipeline. Reusable from publish-stable / publish-channel.
* Returns { coreJson, cliJson } for callers that need the parsed package.jsons.
*
* @param {{ channel?: boolean }} [options]
* @param {boolean} [options.channel] — When true (publish-channel): regenerate
* `reference/` and assert it matches git, but do not sync `SKILL.md` from the
* temporary beta `package.json` version (repo skill stays aligned with stable).
*/
export async function runCheck() {
export async function runCheck(options = {}) {
const channel = options.channel === true;
step("pnpm install --frozen-lockfile");
run("pnpm", ["install", "--frozen-lockfile"]);
@@ -30,16 +37,26 @@ export async function runCheck() {
step("build bailian-cli-core");
run("pnpm", ["--filter", "bailian-cli-core", "run", "build"]);
step("generate skill reference + sync SKILL.md version");
step(
channel
? "generate skill reference (channel: skip SKILL.md version sync)"
: "generate skill reference + sync SKILL.md version",
);
run("pnpm", ["--filter", "bailian-cli", "run", "generate:reference"]);
run("pnpm", ["--filter", "bailian-cli", "run", "sync:skill-version"]);
if (!channel) {
run("pnpm", ["--filter", "bailian-cli", "run", "sync:skill-version"]);
}
step("verify committed skill assets match generators");
step(
channel
? "verify committed reference/ matches generator"
: "verify committed skill assets match generators",
);
run("git", [
"diff",
"--exit-code",
"--",
"skills/bailian-cli/SKILL.md",
...(channel ? [] : ["skills/bailian-cli/SKILL.md"]),
"skills/bailian-cli/reference/",
]);
+1 -1
View File
@@ -66,7 +66,7 @@ try {
// pnpm pack resolves `workspace:*` to the in-tree version, so CLI tarball
// will depend on bailian-cli-core@<betaVersion> after this bump.
await runCheck();
await runCheck({ channel: true });
step(`idempotency: check ${betaVersion} against registry`);
const corePublished = npmViewExists(core.name, betaVersion);