Skip to content

Linger is An Open-Source Personal Agent That Runs Fully on Your PC. We aim to break Big Tech’s grip on AI by bringing powerful local AI to everyday computers through efficient model–harness co-design, so everyone can run their own.

ci: run the path-filter guard once, inside the check action

shoudi zheng4c84cadc697b
diff --git a/.github/actions/check/action.yml b/.github/actions/check/action.yml
index 873829af..22d4227a 100644
--- a/.github/actions/check/action.yml
+++ b/.github/actions/check/action.yml
@@ -5,10 +5,23 @@ inputs:
app:
description: The app whose `make check-<app>` target runs.
required: true
+ changes-result:
+ description: The changes job's result. The job runs when the path filter failed, so this step can fail it instead of letting a skip pass.
+ required: true
runs:
using: composite
steps:
+ # GitHub does not enforce required composite inputs, so anything but an
+ # explicit success fails, a missing input included.
+ - name: Fail when the path filter failed
+ if: inputs.changes-result != 'success'
+ shell: bash
+ env:
+ CHANGES_RESULT: ${{ inputs.changes-result }}
+ run: |
+ echo "::error::The changes job did not succeed (${CHANGES_RESULT:-not passed}); no check can be skipped."
+ exit 1
# teamhub runs only Go. computer-go's tests run the managed-tools scripts,
# which need the pinned Node but no workspace packages.
# Each Go check keeps its own build and module cache, so one job's save
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 342158bd..d8122156 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -159,17 +159,13 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.packages == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: packages
+ changes-result: ${{ needs.changes.result }}
teamhub_cli:
name: check (teamhub-cli)
@@ -177,17 +173,13 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs['teamhub-cli'] == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: teamhub-cli
+ changes-result: ${{ needs.changes.result }}
installer:
name: check (installer)
@@ -195,17 +187,13 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.installer == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: installer
+ changes-result: ${{ needs.changes.result }}
desktop:
name: check (desktop)
@@ -213,17 +201,13 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.desktop == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: desktop
+ changes-result: ${{ needs.changes.result }}
contracts:
name: check (contracts)
@@ -231,17 +215,13 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.contracts == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: contracts
+ changes-result: ${{ needs.changes.result }}
teamhub:
name: check (teamhub)
@@ -249,17 +229,13 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.teamhub == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: teamhub
+ changes-result: ${{ needs.changes.result }}
computer_go:
name: check (computer-go)
@@ -267,14 +243,10 @@ jobs:
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs['computer-go'] == 'true') }}
runs-on: ubuntu-latest
steps:
- - name: Fail when the path filter failed
- if: needs.changes.result != 'success'
- run: |
- echo "::error::The changes job did not succeed (${{ needs.changes.result }}); no check can be skipped."
- exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: ./.github/actions/check
with:
app: computer-go
+ changes-result: ${{ needs.changes.result }}