Skip to content

Commit

Permalink
[skip ci] Update version script.
Browse files Browse the repository at this point in the history
  • Loading branch information
joshwilsonvu committed Aug 31, 2024
1 parent 856adab commit 0f3be56
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
version:
name: Version
runs-on: ubuntu-latest
if: github.ref_name == 'main'
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -36,6 +37,7 @@ jobs:
uses: peter-evans/create-pull-request@v6
with:
branch: "gh-action-version"
base: main
delete-branch: true
title: "Update package versions"
body: "Merging this PR will publish packages to npm at the new version."
Expand Down
8 changes: 6 additions & 2 deletions scripts/version.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,12 @@ pluginPackageJson.version = newVersion;
standalonePackageJson.version = newVersion;

await Promise.all([
fs.writeFile(pluginPackageJsonPath, JSON.stringify(pluginPackageJson, null, 2), "utf-8"),
fs.writeFile(standalonePackageJsonPath, JSON.stringify(standalonePackageJson, null, 2), "utf-8"),
fs.writeFile(pluginPackageJsonPath, JSON.stringify(pluginPackageJson, null, 2) + "\n", "utf-8"),
fs.writeFile(
standalonePackageJsonPath,
JSON.stringify(standalonePackageJson, null, 2) + "\n",
"utf-8"
),
]);
await new Promise((resolve, reject) => {
exec(
Expand Down

0 comments on commit 0f3be56

Please sign in to comment.