-
Notifications
You must be signed in to change notification settings - Fork 25
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
1b4634e
commit c14b419
Showing
1 changed file
with
43 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Update Docs | ||
|
||
permissions: | ||
contents: write | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
jobs: | ||
Build: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
package-name: ${{ steps.packageInfo.outputs.package-name }} | ||
package-version: ${{ steps.packageInfo.outputs.package-version }} | ||
commit-msg: ${{ steps.packageInfo.outputs.commit-msg }} | ||
|
||
steps: | ||
- name: Checkout Commit | ||
uses: actions/checkout@v2 | ||
|
||
- name: Parsing Package Info | ||
id: packageInfo | ||
run: | | ||
echo "::set-output name=package-name::$(jq -r .name package.json)" | ||
echo "::set-output name=package-version::$(jq -r .version package.json)" | ||
echo "::set-output name=commit-msg::$(git log -1 --pretty=%B)" | ||
- name: Setup Node.js environment | ||
uses: actions/[email protected] | ||
|
||
- name: Install Dependencies | ||
run: yarn | ||
|
||
- name: Build | ||
run: yarn run build:all | ||
|
||
- name: Publish to Pages | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
publish_branch: gh-pages | ||
publish_dir: ./docs | ||
github_token: ${{ secrets.GITHUB_TOKEN }} |