generated from halo-dev/plugin-starter
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add check step for github action (#40)
- Loading branch information
Showing
9 changed files
with
336 additions
and
319 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 |
---|---|---|
|
@@ -18,6 +18,49 @@ on: | |
- "!**.md" | ||
|
||
jobs: | ||
check: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v2 | ||
with: | ||
distribution: "temurin" | ||
cache: "gradle" | ||
java-version: 17 | ||
- name: Set up Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- uses: pnpm/[email protected] | ||
name: Install pnpm | ||
id: pnpm-install | ||
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('**/console/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
- name: Install Frontend Dependencies | ||
run: | | ||
./gradlew pnpmInstall | ||
- name: Run code lint check | ||
run: | | ||
./gradlew pnpm_lint | ||
- name: Run TypeScript type check | ||
run: | | ||
./gradlew pnpm_type-check | ||
- name: Run unit test | ||
run: | | ||
./gradlew pnpm_test-unit | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
@@ -27,8 +70,8 @@ jobs: | |
- name: Set up JDK 17 | ||
uses: actions/setup-java@v2 | ||
with: | ||
distribution: 'temurin' | ||
cache: 'gradle' | ||
distribution: "temurin" | ||
cache: "gradle" | ||
java-version: 17 | ||
- name: Set up Node.js | ||
uses: actions/setup-node@v3 | ||
|
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
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
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.