-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
6 changed files
with
3,883 additions
and
12,591 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 |
---|---|---|
@@ -1,45 +1,69 @@ | ||
name: CI/CD | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
compile-and-publish: | ||
name: Compile and Publish | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout project | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.ACCESS_TOKEN }} | ||
- name: Setup Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 16.x | ||
- name: Install dependencies | ||
run: | | ||
npm ci | ||
- name: Clean files | ||
run: | | ||
npm run clean | ||
- name: Convert Stylus to CSS | ||
run: | | ||
npm run stylus | ||
- name: Compile files | ||
run: | | ||
npm run compile-single | ||
- name: Deploy files | ||
uses: JamesIves/github-pages-deploy-action@v4 | ||
with: | ||
folder: dist | ||
token: ${{ secrets.ACCESS_TOKEN }} | ||
branch: gh-pages | ||
clean-exclude: | | ||
assets | ||
images | ||
LICENSE | ||
favicon.ico | ||
index.html | ||
commit-message: ${{ github.event.head_commit.message }} @ ${{ github.sha }} 🚀 | ||
compile-and-publish: | ||
name: Compile and Publish | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout project | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.ACCESS_TOKEN }} | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 16 | ||
|
||
- name: Install pnpm | ||
uses: pnpm/action-setup@v2 | ||
with: | ||
version: 8 | ||
run_install: false | ||
|
||
- name: Get pnpm store directory | ||
shell: bash | ||
run: | | ||
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV | ||
- uses: actions/cache@v3 | ||
name: Setup pnpm cache | ||
with: | ||
path: ${{ env.STORE_PATH }} | ||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
- name: Install dependencies | ||
run: pnpm install | ||
|
||
- name: Clean files | ||
run: | | ||
pnpm clean | ||
- name: Convert Stylus to CSS | ||
run: | | ||
pnpm stylus | ||
- name: Compile files | ||
run: | | ||
pnpm compile-single | ||
- name: Deploy files | ||
uses: JamesIves/github-pages-deploy-action@v4 | ||
with: | ||
folder: dist | ||
token: ${{ secrets.ACCESS_TOKEN }} | ||
branch: gh-pages | ||
clean-exclude: | | ||
assets | ||
images | ||
LICENSE | ||
favicon.ico | ||
index.html | ||
commit-message: ${{ github.event.head_commit.message }} @ ${{ github.sha }} 🚀 |
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 |
---|---|---|
@@ -1,23 +1,34 @@ | ||
name: Validation | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
validation: | ||
name: Validate build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- name: Setup Node.js | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 12.x | ||
- name: Install dependencies | ||
run: | | ||
npm ci | ||
- name: Compile files | ||
run: | | ||
npm run compile | ||
validation: | ||
name: Validate build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout project | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.ACCESS_TOKEN }} | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 16 | ||
|
||
- name: Install pnpm | ||
uses: pnpm/action-setup@v2 | ||
with: | ||
version: 8 | ||
run_install: false | ||
|
||
- name: Install dependencies | ||
run: pnpm install | ||
|
||
- name: Compile files | ||
run: | | ||
pnpm compile |
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
Oops, something went wrong.