Skip to content

Commit a681d2c

Browse files
committed
Add prepare_release.ps1 script
Fixes MessagePack-CSharp#1195
1 parent cd0bfa0 commit a681d2c

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

prepare_release.ps1

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Calculate the NPM package version, assuming the version change is in a new commit.
2+
git commit --allow-empty -m "Dummy commit" -q
3+
$NpmPackageVersion = (nbgv get-version -f json | ConvertFrom-Json).NpmPackageVersion
4+
git reset --mixed HEAD~ -q
5+
6+
# Stamp the version into the package.json file and commit.
7+
pushd $PSScriptRoot/src/MessagePack.UnityClient/Assets/Scripts/MessagePack
8+
npm version $NpmPackageVersion --no-git-tag-version --allow-same-version
9+
git add package.json
10+
popd
11+
git commit -m "Stamp unity package version as $NpmPackageVersion"
12+
13+
# Tag the release
14+
nbgv tag

0 commit comments

Comments
 (0)