From 74b33f79b088d67ef23b477e21c45e97584bbba5 Mon Sep 17 00:00:00 2001 From: Masafumi Koba <473530+ybiquitous@users.noreply.github.com> Date: Tue, 7 Jun 2022 19:27:56 +0900 Subject: [PATCH] Simplify CI settings via reusable workflow (#251) --- .github/workflows/nodejs.yml | 52 +++--------------------------------- 1 file changed, 4 insertions(+), 48 deletions(-) diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 5a4d795..e5ca236 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -11,53 +11,9 @@ on: jobs: lint: - name: Lint - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v3 - - - name: Use Node.js LTS - uses: actions/setup-node@v3 - with: - node-version: 'lts/*' - cache: npm - - - name: Install latest npm - run: npm install --global npm@latest - - - name: Install dependencies - run: npm ci - - - name: Lint - run: npm run lint + uses: stylelint/.github/.github/workflows/lint.yml@main test: - name: Test on Node.js ${{ matrix.node }} and ${{ matrix.os }} - - runs-on: ${{ matrix.os }} - - strategy: - fail-fast: false - matrix: - node: [12, 14, 16, 18] - os: [ubuntu-latest, windows-latest, macos-latest] - - steps: - - uses: actions/checkout@v3 - - - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node }} - cache: npm - - - name: Install latest npm - run: npm install --global npm@latest - - - name: Install dependencies - run: npm ci - - - name: Test - run: npm test + uses: stylelint/.github/.github/workflows/test.yml@main + with: + os: '["ubuntu-latest", "windows-latest", "macos-latest"]'