-
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
Showing
2 changed files
with
27 additions
and
29 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 |
---|---|---|
|
@@ -96,42 +96,36 @@ jobs: | |
if: steps.yarn-cache.outputs.cache-hit != 'true' | ||
run: yarn | ||
|
||
- name: 'Automated Version Bump (Beta)' | ||
uses: 'phips28/gh-action-bump-version@master' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_USER: 'DIVE[bot]' | ||
GITHUB_EMAIL: '[email protected]' | ||
with: | ||
target-branch: 'trunk' | ||
commit-message: 'DIVE[bot]: Beta {{version}} [pre-beta] [skip ci]' | ||
skip-push: 'true' | ||
skip-tag: 'true' | ||
- name: Register git user | ||
run: | | ||
git config user.name "GitHub Actions" | ||
git config user.email "[email protected]" | ||
- name: 'Create beta branch' | ||
run: git checkout -b beta/v$(node -p "require('./package.json').version") | ||
- name: 'Bump version to beta' | ||
run: | | ||
npm version prerelease --preid=beta --no-git-tag-version | ||
git add package.json | ||
- name: Build DIVE | ||
run: yarn build | ||
- name: Add build files | ||
run: git add ./build -f | ||
|
||
- name: 'Add Build files to git' | ||
run: | | ||
git add ./build -f | ||
echo "Staged build files! Status:" | ||
git status | ||
- name: 'Create beta branch' | ||
run: | ||
git checkout -b beta/v$(node -p "require('./package.json').version") | ||
|
||
- name: 'Commit changes' | ||
- name: Commit changes | ||
run: | | ||
echo "Committing ..." | ||
git commit -m "Beta v$(node -p "require('./package.json').version") [skip ci]" | ||
echo "Committed! Status:" | ||
git status | ||
git commit -m "Beta v$(node -p "require('./package.json').version")" | ||
git tag -a v$(node -p "require('./package.json').version") -m "Beta v$(node -p "require('./package.json').version")" | ||
- name: 'Add beta tag' | ||
run: git tag -a v$(node -p "require('./package.json').version") -m "Beta v$(node -p "require('./package.json').version")" | ||
- name: Push changes | ||
run: | | ||
git push origin beta/v$(node -p "require('./package.json').version") --follow-tags | ||
- name: 'Push to beta branch' | ||
run: git push origin beta/v$(node -p "require('./package.json').version") && git push origin tag v$(node -p "require('./package.json').version") | ||
- name: Authenticate with NPM | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
run: echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" > ~/.npmrc | ||
|
||
- name: Publish Beta tag to npm | ||
run: | | ||
|
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