From fa18acef1a008b4d277235e79d91cec1f770daff Mon Sep 17 00:00:00 2001 From: qcjxs <1447515520@qq.com> Date: Mon, 11 Sep 2023 14:39:00 +0800 Subject: [PATCH] Create lstest.yml --- .github/workflows/lstest.yml | 57 ++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 .github/workflows/lstest.yml diff --git a/.github/workflows/lstest.yml b/.github/workflows/lstest.yml new file mode 100644 index 000000000000..d6ead738e264 --- /dev/null +++ b/.github/workflows/lstest.yml @@ -0,0 +1,57 @@ +name: Node CI + +on: + push: + branches: + - next + - feat/** + pull_request: + branches: + - next + +permissions: + contents: read # to fetch code (actions/checkout) + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + fail-fast: false + matrix: + node-version: [14.x, 16.x] + + steps: + - name: Checkout + uses: actions/checkout@v3 + with : + ref : ${{ github.ref || github.head_ref || github.ref_name }} + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + + # Bootstrap project + - name: Cache pnpm modules + uses: actions/cache@v3 + with: + path: ~/.pnpm-store + key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}- + - name: install + uses: pnpm/action-setup@v2.4.0 + with: + version: 7 + run_install: | + - recursive: true + args: [--frozen-lockfile] + - name: lint + run: pnpm lint + - name: build + run: pnpm build + - name: test + run: pnpm test + env: + CI: true