From 97ee481bf6868910700bf9f55eb8caed22701686 Mon Sep 17 00:00:00 2001 From: Jordan Jensen Date: Wed, 20 Mar 2024 14:27:07 -0700 Subject: [PATCH 1/6] Isolate lint GitHub Workflow --- .github/workflows/lint.yaml | 15 +++++++++++++++ .github/workflows/pull-request.yaml | 2 ++ .github/workflows/vscode.yaml | 4 ---- 3 files changed, 17 insertions(+), 4 deletions(-) create mode 100644 .github/workflows/lint.yaml diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml new file mode 100644 index 000000000..760991aba --- /dev/null +++ b/.github/workflows/lint.yaml @@ -0,0 +1,15 @@ +name: lint +on: [workflow_call] +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: extractions/setup-just@v2 + - uses: actions/setup-node@v4 + with: + node-version: '20' + # cache: 'npm' + # cache-dependency-path: '**/package-lock.json' + - run: just vscode lint + - run: just vscode check-format diff --git a/.github/workflows/pull-request.yaml b/.github/workflows/pull-request.yaml index 8bf5c6f8a..b937902e9 100644 --- a/.github/workflows/pull-request.yaml +++ b/.github/workflows/pull-request.yaml @@ -6,6 +6,8 @@ concurrency: group: ${{ github.head_ref }} cancel-in-progress: true jobs: + lint: + uses: ./.github/workflows/lint.yaml # Unit Tests agent: uses: ./.github/workflows/agent.yaml diff --git a/.github/workflows/vscode.yaml b/.github/workflows/vscode.yaml index e9f9eb399..c3451022b 100644 --- a/.github/workflows/vscode.yaml +++ b/.github/workflows/vscode.yaml @@ -29,8 +29,6 @@ jobs: path: ./extensions/vscode/.vscode-test/vscode-* key: ${{ matrix.runner }}-vscode-${{ env.VSCODE_VERSION }}-${{ steps.get-date.outputs.date }} - run: just vscode configure - - run: just vscode lint - - run: just vscode check-format - run: just vscode test - uses: actions/cache/save@v3 if: steps.cache.outputs.cache-hit != 'true' @@ -53,8 +51,6 @@ jobs: path: ./extensions/vscode/.vscode-test/vscode-* key: docker-vscode-${{ env.VSCODE_VERSION }}-${{ steps.get-date.outputs.date }} - run: just vscode configure - - run: just vscode lint - - run: just vscode check-format - run: just vscode test - uses: actions/cache/save@v3 if: steps.cache.outputs.cache-hit != 'true' From 809fabc887a144f947a3a5a847ad2cddeb194d20 Mon Sep 17 00:00:00 2001 From: Jordan Jensen Date: Wed, 20 Mar 2024 14:33:05 -0700 Subject: [PATCH 2/6] Test isolated --- .github/workflows/lint.yaml | 6 +++--- .github/workflows/pull-request.yaml | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index 760991aba..f71551ada 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -1,5 +1,5 @@ name: lint -on: [workflow_call] +on: [pull_request] jobs: lint: runs-on: ubuntu-latest @@ -9,7 +9,7 @@ jobs: - uses: actions/setup-node@v4 with: node-version: '20' - # cache: 'npm' - # cache-dependency-path: '**/package-lock.json' + cache: 'npm' + cache-dependency-path: '**/package-lock.json' - run: just vscode lint - run: just vscode check-format diff --git a/.github/workflows/pull-request.yaml b/.github/workflows/pull-request.yaml index b937902e9..65f4d67fc 100644 --- a/.github/workflows/pull-request.yaml +++ b/.github/workflows/pull-request.yaml @@ -6,8 +6,8 @@ concurrency: group: ${{ github.head_ref }} cancel-in-progress: true jobs: - lint: - uses: ./.github/workflows/lint.yaml + # lint: + # uses: ./.github/workflows/lint.yaml # Unit Tests agent: uses: ./.github/workflows/agent.yaml From 5d0ce6d1787cf449600c721919c62231cc651b3f Mon Sep 17 00:00:00 2001 From: Jordan Jensen Date: Wed, 20 Mar 2024 14:40:59 -0700 Subject: [PATCH 3/6] another --- extensions/vscode/justfile | 8 -------- 1 file changed, 8 deletions(-) diff --git a/extensions/vscode/justfile b/extensions/vscode/justfile index d0c9a1b86..078f7c067 100644 --- a/extensions/vscode/justfile +++ b/extensions/vscode/justfile @@ -98,17 +98,9 @@ install os="$(just ../../os)" arch="$(just ../../arch)" editor="code": # Performs static code analysis with ESLint lint: - #!/usr/bin/env bash - set -eou pipefail - {{ _with_debug }} - npm run lint format: - #!/usr/bin/env bash - set -eou pipefail - {{ _with_debug }} - npm run format check-format: From 60baca6002ae89087b4e4988eb5cd1abb1fe501b Mon Sep 17 00:00:00 2001 From: Jordan Jensen Date: Wed, 20 Mar 2024 14:41:17 -0700 Subject: [PATCH 4/6] a --- extensions/vscode/justfile | 4 ---- 1 file changed, 4 deletions(-) diff --git a/extensions/vscode/justfile b/extensions/vscode/justfile index 078f7c067..768acf0ef 100644 --- a/extensions/vscode/justfile +++ b/extensions/vscode/justfile @@ -104,10 +104,6 @@ format: npm run format check-format: - #!/usr/bin/env bash - set -eou pipefail - {{ _with_debug }} - npm run check-format # Packages the extension. From d7b8cb397f41ec6774b760459865f0f7fef6ae63 Mon Sep 17 00:00:00 2001 From: Jordan Jensen Date: Wed, 20 Mar 2024 14:48:32 -0700 Subject: [PATCH 5/6] Fetch-tags --- .github/workflows/lint.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index f71551ada..d9b2c9c53 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -5,6 +5,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + with: + fetch-tags: true - uses: extractions/setup-just@v2 - uses: actions/setup-node@v4 with: From ecce14c83d7530483028cb87777c49b0e50a4227 Mon Sep 17 00:00:00 2001 From: Jordan Jensen Date: Wed, 20 Mar 2024 14:49:28 -0700 Subject: [PATCH 6/6] With fetch-depth --- .github/workflows/lint.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index d9b2c9c53..6359432df 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -6,7 +6,7 @@ jobs: steps: - uses: actions/checkout@v4 with: - fetch-tags: true + fetch-depth: 0 - uses: extractions/setup-just@v2 - uses: actions/setup-node@v4 with: