mirror of
https://github.com/Tencent/BrowserSkill.git
synced 2026-09-10 13:01:23 +08:00
Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a928a9fb76 | ||
|
|
0b2d7e95cc | ||
|
|
556bea1645 |
+1
-1
@@ -7,7 +7,7 @@ Starting from 0.2.0, CLI / Extension / DSH Plugin share the same version number.
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
## [0.2.0] - 2026-09-XX
|
||||
## [0.2.0] - 2026-09-02
|
||||
|
||||
### Added
|
||||
- File transfer: upload and download support across CLI, Extension, and DSH Plugin
|
||||
|
||||
Generated
+2
-2
@@ -134,7 +134,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "bsk"
|
||||
version = "0.1.11"
|
||||
version = "0.2.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"base64",
|
||||
@@ -169,7 +169,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "bsk-protocol"
|
||||
version = "0.1.11"
|
||||
version = "0.2.0"
|
||||
dependencies = [
|
||||
"schemars",
|
||||
"semver",
|
||||
|
||||
+2
-2
@@ -7,7 +7,7 @@ members = [
|
||||
default-members = ["crates/bsk-cli"]
|
||||
|
||||
[workspace.package]
|
||||
version = "0.1.11"
|
||||
version = "0.2.0"
|
||||
edition = "2024"
|
||||
rust-version = "1.85"
|
||||
license = "MIT"
|
||||
@@ -43,7 +43,7 @@ rand = "0.8"
|
||||
uuid = { version = "1", features = ["v4", "serde"] }
|
||||
|
||||
# Workspace crates (version required for `cargo publish` of dependents)
|
||||
bsk-protocol = { version = "0.1.9", path = "crates/bsk-protocol" }
|
||||
bsk-protocol = { version = "0.2.0", path = "crates/bsk-protocol" }
|
||||
|
||||
[profile.release]
|
||||
strip = "symbols"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@browser-skill/extension",
|
||||
"version": "0.1.7",
|
||||
"version": "0.2.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
|
||||
@@ -122,8 +122,8 @@ describe("App", () => {
|
||||
|
||||
expect(screen.queryByText(/^扩展 v/)).toBeNull();
|
||||
expect(screen.queryByText(/^daemon v/)).toBeNull();
|
||||
expect(screen.getByTitle("扩展版本").textContent).toBe(EXTENSION_VERSION);
|
||||
expect(screen.getByTitle("bsk 版本").textContent).toBe(mockDaemonVersion);
|
||||
expect(screen.getByTitle("扩展版本").textContent).toBe(`Ext ${EXTENSION_VERSION}`);
|
||||
expect(screen.getByTitle("bsk 版本").textContent).toBe(`CLI ${mockDaemonVersion}`);
|
||||
expect(screen.getByText("03c3e47f")).toBeTruthy();
|
||||
|
||||
const copyButton = screen.getByRole("button", { name: "复制实例 ID" });
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "@wxg-prc-cpg/browser-skill-dsh-plugin",
|
||||
"description": "DeepSeek Harness tool plugin that exposes BrowserSkill browser automation (browser_* tools) to the model",
|
||||
"version": "0.1.2",
|
||||
"version": "0.2.0",
|
||||
"license": "MIT",
|
||||
"publishConfig": {
|
||||
"access": "public",
|
||||
|
||||
+38
-23
@@ -51,7 +51,9 @@ const { values, positionals } = parseArgs({
|
||||
});
|
||||
|
||||
if (values.help) {
|
||||
console.log(readFileSync(new URL(import.meta.url), "utf8").match(/\/\*\*([\s\S]*?)\*\//)?.[1] ?? "");
|
||||
console.log(
|
||||
readFileSync(new URL(import.meta.url), "utf8").match(/\/\*\*([\s\S]*?)\*\//)?.[1] ?? "",
|
||||
);
|
||||
process.exit(0);
|
||||
}
|
||||
|
||||
@@ -60,9 +62,7 @@ const pushAfter = values.push;
|
||||
const pushTagsOnly = values["push-tags"];
|
||||
const noCommit = values["no-commit"];
|
||||
const onlyRaw = values.only;
|
||||
const components = onlyRaw
|
||||
? onlyRaw.split(",").map((s) => s.trim().toLowerCase())
|
||||
: ALL_COMPONENTS;
|
||||
const components = onlyRaw ? onlyRaw.split(",").map((s) => s.trim().toLowerCase()) : ALL_COMPONENTS;
|
||||
|
||||
for (const c of components) {
|
||||
if (!ALL_COMPONENTS.includes(c)) {
|
||||
@@ -95,7 +95,9 @@ if (pushTagsOnly) {
|
||||
|
||||
const newVersion = positionals[0];
|
||||
if (!newVersion) {
|
||||
console.error("Usage: node scripts/release.mjs <version> [--dry-run] [--push] [--only cli,ext,dsh]");
|
||||
console.error(
|
||||
"Usage: node scripts/release.mjs <version> [--dry-run] [--push] [--only cli,ext,dsh]",
|
||||
);
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
@@ -110,8 +112,9 @@ if (!/^\d+\.\d+\.\d+(-[\w.]+)?$/.test(newVersion)) {
|
||||
|
||||
function readCurrentVersions() {
|
||||
const cargo = readFileSync(VERSION_FILES.cargo, "utf8");
|
||||
const cargoVer = cargo.match(/^\[workspace\.package\]\s*\nversion\s*=\s*"([^"]+)"/m)?.[1]
|
||||
?? cargo.match(/^version\s*=\s*"([^"]+)"/m)?.[1];
|
||||
const cargoVer =
|
||||
cargo.match(/^\[workspace\.package\]\s*\nversion\s*=\s*"([^"]+)"/m)?.[1] ??
|
||||
cargo.match(/^version\s*=\s*"([^"]+)"/m)?.[1];
|
||||
|
||||
const extPkg = JSON.parse(readFileSync(VERSION_FILES.extension, "utf8"));
|
||||
const dshPkg = JSON.parse(readFileSync(VERSION_FILES.dshPlugin, "utf8"));
|
||||
@@ -170,19 +173,17 @@ function updateChangelog(version) {
|
||||
}
|
||||
|
||||
const today = new Date().toISOString().slice(0, 10);
|
||||
const unreleased = /^## \[Unreleased\]/m;
|
||||
if (unreleased.test(content)) {
|
||||
content = content.replace(
|
||||
unreleased,
|
||||
`## [Unreleased]\n\n## [${version}] - ${today}`,
|
||||
);
|
||||
const escapedVer = version.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
||||
|
||||
// First: fill in any date-placeholder line for this version (e.g. "## [0.2.0] - 2026-09-XX")
|
||||
const versionPlaceholder = new RegExp(`^## \\[${escapedVer}\\]\\s*-\\s*\\d{4}-\\d{2}-XX`, "m");
|
||||
if (versionPlaceholder.test(content)) {
|
||||
content = content.replace(versionPlaceholder, `## [${version}] - ${today}`);
|
||||
} else {
|
||||
const versionPlaceholder = new RegExp(
|
||||
`^## \\[${version.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")}\\]\\s*-\\s*\\d{4}-\\d{2}-XX`,
|
||||
"m",
|
||||
);
|
||||
if (versionPlaceholder.test(content)) {
|
||||
content = content.replace(versionPlaceholder, `## [${version}] - ${today}`);
|
||||
// Otherwise: insert a new section after [Unreleased]
|
||||
const unreleased = /^## \[Unreleased\]/m;
|
||||
if (unreleased.test(content)) {
|
||||
content = content.replace(unreleased, `## [Unreleased]\n\n## [${version}] - ${today}`);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -195,13 +196,25 @@ function updateChangelog(version) {
|
||||
|
||||
const writes = [
|
||||
{ path: VERSION_FILES.cargo, content: bumpCargo(newVersion), label: "Cargo.toml" },
|
||||
{ path: VERSION_FILES.extension, content: bumpPackageJson(VERSION_FILES.extension, newVersion), label: "Extension package.json" },
|
||||
{ path: VERSION_FILES.dshPlugin, content: bumpPackageJson(VERSION_FILES.dshPlugin, newVersion), label: "DSH Plugin package.json" },
|
||||
{
|
||||
path: VERSION_FILES.extension,
|
||||
content: bumpPackageJson(VERSION_FILES.extension, newVersion),
|
||||
label: "Extension package.json",
|
||||
},
|
||||
{
|
||||
path: VERSION_FILES.dshPlugin,
|
||||
content: bumpPackageJson(VERSION_FILES.dshPlugin, newVersion),
|
||||
label: "DSH Plugin package.json",
|
||||
},
|
||||
];
|
||||
|
||||
const changelogUpdate = updateChangelog(newVersion);
|
||||
if (changelogUpdate) {
|
||||
writes.push({ path: changelogUpdate.path, content: changelogUpdate.content, label: "CHANGELOG.md" });
|
||||
writes.push({
|
||||
path: changelogUpdate.path,
|
||||
content: changelogUpdate.content,
|
||||
label: "CHANGELOG.md",
|
||||
});
|
||||
}
|
||||
|
||||
for (const w of writes) {
|
||||
@@ -237,7 +250,9 @@ if (noCommit || dryRun) {
|
||||
}
|
||||
|
||||
console.log("\nCommitting...");
|
||||
run("git add Cargo.toml Cargo.lock apps/extension/package.json packages/dsh-plugin-browserskill/package.json CHANGELOG.md 2>/dev/null || true");
|
||||
run(
|
||||
"git add Cargo.toml Cargo.lock apps/extension/package.json packages/dsh-plugin-browserskill/package.json CHANGELOG.md 2>/dev/null || true",
|
||||
);
|
||||
run(`git commit -m "chore(release): ${newVersion}"`);
|
||||
|
||||
console.log("Tagging...");
|
||||
|
||||
Reference in New Issue
Block a user