-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update CONTRIBUTING, add publish script (bump.sh)n
- Loading branch information
1 parent
03a38fb
commit 1877396
Showing
2 changed files
with
59 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/bin/sh | ||
# Small janky utility for bumping package versions across the monorepo, | ||
# because `npm version` doesn't really work w/ pnpm | ||
|
||
# get version from 1st argument | ||
VERSION=$1 | ||
|
||
# error if no version | ||
if [ -z "$VERSION" ]; then | ||
echo "Usage: bump.sh <version>" | ||
exit 1 | ||
fi | ||
|
||
for d in packages/*; do | ||
echo "Bumping $d to version $VERSION" | ||
npm pkg set -w $d version=$VERSION | ||
done | ||
|
||
echo "" | ||
echo "Bumping @counterscale/server subdep in packages/cli to version $VERSION" | ||
npm pkg set -w packages/cli dependencies.@counterscale/server=$VERSION | ||
|
||
|
||
echo "" | ||
echo "Next steps ..." | ||
echo "" | ||
echo "$ git diff # Review changes" | ||
echo "$ git commit -am \"$VERSION\"" | ||
echo "$ git tag $VERSION" | ||
echo "$ pnpm publish -r" |