diff options
| author | 2026-01-13 14:41:15 +0800 | |
|---|---|---|
| committer | 2026-01-13 14:41:15 +0800 | |
| commit | d57b1039723dec624bf40e6abb8fb6ca92a8c98c (patch) | |
| tree | 8e5d751273a4721801b29487d10ecc22447547cc /.github | |
| parent | 6295ce99e717fdd1908e5e276bfc2b51792b69f4 (diff) | |
| download | DropOut-d57b1039723dec624bf40e6abb8fb6ca92a8c98c.tar.gz DropOut-d57b1039723dec624bf40e6abb8fb6ca92a8c98c.zip | |
feat: refine GitHub Actions workflow to trigger only on main branch
Diffstat (limited to '.github')
| -rw-r--r-- | .github/workflows/test.yml | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 28f341b..b5311c9 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -2,9 +2,13 @@ name: Test & Build on: push: - branches: ["main", "master", "dev"] + branches: ["main"] + paths-ignore: + - "**.md" + - "ui/**" pull_request: - branches: ["main", "master", "dev"] + branches: ["main"] + workflow_dispatch: env: CARGO_TERM_COLOR: always @@ -16,7 +20,8 @@ jobs: strategy: fail-fast: false matrix: - platform: [ubuntu-22.04, windows-latest, macos-14] + # On Push: Linux only. On PR: All platforms. + platform: ${{ (github.event_name == 'pull_request') && fromJson('["ubuntu-22.04", "windows-latest", "macos-14"]') || fromJson('["ubuntu-22.04"]') }} steps: - uses: actions/checkout@v4 |