-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
475dc8e
commit b9c5a63
Showing
2 changed files
with
21 additions
and
9 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 |
---|---|---|
|
@@ -9,8 +9,6 @@ env: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
FORMBUILDER_WEBSITE_DIR: ${{ secrets.FORMBUILDER_WEBSITE_DIR }} | ||
FORMBUILDER_WEBSITE_REPO: ${{ secrets.FORMBUILDER_WEBSITE_REPO }} | ||
|
||
jobs: | ||
build: | ||
|
@@ -41,6 +39,24 @@ jobs: | |
if: success() | ||
run: npx semantic-release | ||
|
||
- name: Deploy the website | ||
- name: Get npm package version using jq | ||
if: success() | ||
run: npm run deploy:site | ||
id: get_version | ||
run: | | ||
VERSION=$(jq -r ".version" package.json) | ||
echo "::set-output name=version::$VERSION" | ||
- name: Deploy the website | ||
env: | ||
VERSION: ${{ steps.get_version.outputs.version }} | ||
run: | | ||
git config --global user.name "GitHub Actions" | ||
git config --global user.email "[email protected]" | ||
git clone https://github.com/kevinchappell/formBuilder-site.git | ||
cd formBuilder-site | ||
npm version ${{ env.version }} | ||
# Commit and push the changes | ||
git commit -am "Update site to ${{ env.version }}" | ||
git push https://${{ secrets.GITHUB_TOKEN }}@github.com/kevinchappell/formBuilder-site.git master |
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