Skip to content

Commit

Permalink
Merge pull request #482 from webcat12345/add-publish-script
Browse files Browse the repository at this point in the history
build(scripts): Add publish script
  • Loading branch information
cmckni3 authored Nov 1, 2023
2 parents 2339c64 + c45a567 commit 7af89e9
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions scripts/publish.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
#!/usr/bin/env bash

set -e

VERSION='invalid'

Help()
{
# Display Help
echo "Add description of the script functions here."
echo
echo "Syntax: publish.sh [-v|h]"
echo "options:"
echo "v Version of package to release"
echo "h Print this Help"
echo
}

while getopts ":hv:" option; do
case $option in
v) # Enter a name
VERSION=$OPTARG;;
h) # display Help
Help
exit;;
\?) # Invalid option
echo "Error: Invalid option"
exit;;
esac
done

echo "Bumping version to ${VERSION}"

npm version ${VERSION} --no-commit-hooks --no-git-tag-version --preid beta

pushd src/lib/ui-switch

npm version ${VERSION} --no-commit-hooks --no-git-tag-version --preid beta

popd

# git commit -am 'chore(version): Bump version'

# git tag -a "${VERSION}" -m "Version ${VERSION}"

0 comments on commit 7af89e9

Please sign in to comment.