This repository has been archived by the owner on Jun 18, 2024. It is now read-only.
generated from actions/javascript-action
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1eab8b8
commit d05202b
Showing
1 changed file
with
4 additions
and
4 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,18 +26,18 @@ jobs: | |
MAJOR_VERSION_NUMBER=$(echo "$VERSION_NUMBER" | cut -d '.' -f 1) | ||
VERSION=$(echo "v$VERSION_NUMBER") | ||
MAJOR_VERSION=$(echo "v$MAJOR_VERSION_NUMBER") | ||
# Prepare code to upload | ||
npm run all | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git add . | ||
git commit -m "Version $VERSION" | ||
git push origin main | ||
# Create or update a Git tag with the version number | ||
git tag -f -a "$VERSION" -m "Version $VERSION" | ||
# Check if the major tag already exists | ||
if git rev-parse "$MAJOR_VERSION" >/dev/null 2>&1; then | ||
# Update the existing major tag | ||
|
@@ -46,7 +46,7 @@ jobs: | |
# Create a new tag | ||
git tag -a "$MAJOR_VERSION" -m "Version $MAJOR_VERSION" | ||
fi | ||
# Push the Git tags to GitHub | ||
git push origin "$VERSION" --force | ||
git push origin "$MAJOR_VERSION" --force |