diff --git a/.github/workflows/build-assets.yml b/.github/workflows/build-assets.yml index 8ad36cd20b..388d60618d 100644 --- a/.github/workflows/build-assets.yml +++ b/.github/workflows/build-assets.yml @@ -11,20 +11,15 @@ jobs: build: runs-on: ubuntu-latest - strategy: - matrix: - node-version: - - 14.x - steps: - name: Checkout uses: actions/checkout@v2 - - name: Use Node.js ${{ matrix.node-version }} + - name: Use Node.js v14 uses: actions/setup-node@v2 with: - node-version: ${{ matrix.node-version }} + node-version: '14' cache: 'yarn' - - name: build file + - name: Build file run: yarn && npm run build:all - name: Deploy uses: peaceiris/actions-gh-pages@v3 diff --git a/.github/workflows/docker-release.yml b/.github/workflows/docker-release.yml index 8f3a77e0f7..ad05e4ea82 100644 --- a/.github/workflows/docker-release.yml +++ b/.github/workflows/docker-release.yml @@ -48,5 +48,5 @@ jobs: tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} platforms: linux/amd64,linux/arm/v7,linux/arm64 - cache-from: type=gha,scope=${{ github.workflow }} - cache-to: type=gha,mode=max,scope=${{ github.workflow }} + cache-from: type=gha,scope=docker-release + cache-to: type=gha,mode=max,scope=docker-release diff --git a/.github/workflows/docker-test.yml b/.github/workflows/docker-test.yml index 7ce30af779..0cf36aca5c 100644 --- a/.github/workflows/docker-test.yml +++ b/.github/workflows/docker-test.yml @@ -38,8 +38,10 @@ jobs: load: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} - cache-from: type=gha,scope=${{ github.workflow }} - cache-to: type=gha,mode=max,scope=${{ github.workflow }} + cache-from: | + type=gha,scope=docker-test + type=gha,scope=docker-release + cache-to: type=gha,mode=max,scope=docker-test - name: Run dockerfile run: | diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index e44f5f39f9..141cf13fb3 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -6,7 +6,7 @@ on: - master jobs: - build: + format: runs-on: ubuntu-latest steps: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9412120fd1..61fae65ac3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -15,8 +15,9 @@ jobs: strategy: matrix: - node-version: ['14.x'] + node-version: ['14', '16'] + name: Node ${{ matrix.node-version }} steps: - uses: actions/checkout@v2 - uses: actions/setup-node@v2 diff --git a/package.json b/package.json index 5768e59062..b8c20d1406 100644 --- a/package.json +++ b/package.json @@ -16,9 +16,9 @@ "build:radar": "node scripts/workflow/build-radar.js", "build:maintainer": "node scripts/workflow/build-maintainer.js", "lint": "eslint .", - "format": "eslint \"**/*.js\" --fix && node docs/.format/format.js && prettier \"**/*.{js,json}\" --write", - "format:staged": "eslint \"**/*.js\" --fix && node docs/.format/format.js --staged && pretty-quick --staged --verbose --pattern \"**/*.{js,json}\"", - "format:check": "eslint \"**/*.js\" && prettier-check \"**/*.{js,json}\"", + "format": "eslint \"**/*.{js,yml}\" --fix && node docs/.format/format.js && prettier \"**/*.{js,json}\" --write", + "format:staged": "eslint \"**/*.{js,yml}\" --fix && node docs/.format/format.js --staged && pretty-quick --staged --verbose --pattern \"**/*.{js,json}\"", + "format:check": "eslint \"**/*.{js,yml}\" && prettier-check \"**/*.{js,json}\"", "test": "npm run format:check && cross-env NODE_ENV=test jest --coverage --runInBand --forceExit", "jest": "cross-env NODE_ENV=test jest --runInBand --forceExit", "jest:watch": "cross-env NODE_ENV=test jest --watch" @@ -152,5 +152,8 @@ "moduleNameMapper": { "@/(.*)": "/lib/$1" } + }, + "nodemonConfig": { + "ext": "art,js,mjs,json" } }