From abc0ad7120aab979bdab544ac5a0270f779168be Mon Sep 17 00:00:00 2001 From: Marco Pasqualetti <24919330+marcalexiei@users.noreply.github.com> Date: Tue, 3 Dec 2024 15:59:10 +0100 Subject: [PATCH] chore(github actions): refine `on` paths (#189) --- .github/workflows/ci-documentation.yml | 10 +++++++++- .github/workflows/deploy-documentation.yml | 2 +- .github/workflows/repo-root-ci.yml | 7 ++++--- .github/workflows/rust.yml | 4 +++- .github/workflows/spell-checking.yml | 2 +- .github/workflows/typescript.yml | 10 +++++++++- 6 files changed, 27 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci-documentation.yml b/.github/workflows/ci-documentation.yml index 182b2eb9..a69df4c2 100644 --- a/.github/workflows/ci-documentation.yml +++ b/.github/workflows/ci-documentation.yml @@ -3,13 +3,21 @@ name: Documentation Website CI on: push: branches: - - main + - 'main' paths: + # ⬇ Keep paths in sync with `typescript.yml` - '.github/**' + - '*' + - '!Cargo.toml' + # ⬆ Keep paths in sync with `typescript.yml` - 'apps/documentation/**' pull_request: paths: + # ⬇ Keep paths in sync with `typescript.yml` - '.github/**' + - '*' + - '!Cargo.toml' + # ⬆ Keep paths in sync with `typescript.yml` - 'apps/documentation/**' jobs: diff --git a/.github/workflows/deploy-documentation.yml b/.github/workflows/deploy-documentation.yml index 8c44a61b..b2b118ea 100644 --- a/.github/workflows/deploy-documentation.yml +++ b/.github/workflows/deploy-documentation.yml @@ -3,7 +3,7 @@ name: Deploy documentation website on AWS S3 on: push: branches: - - main + - 'main' paths: - '.github/**' - 'apps/documentation/**' diff --git a/.github/workflows/repo-root-ci.yml b/.github/workflows/repo-root-ci.yml index 2f840a6e..bdec8776 100644 --- a/.github/workflows/repo-root-ci.yml +++ b/.github/workflows/repo-root-ci.yml @@ -1,4 +1,5 @@ name: Repo root CI + # All workflows are triggered based on specific paths, # the root repository is something that is not applicable to rust nor typescript # so it has been moved in a standalone workflow @@ -6,14 +7,14 @@ name: Repo root CI on: push: branches: - - main + - 'main' paths: - '.github/**' - - './*' + - '*' pull_request: paths: - '.github/**' - - './*' + - '*' jobs: build-and-test: diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index d1462255..5a215888 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -3,13 +3,15 @@ name: Rust CI on: push: branches: - - main + - 'main' paths: - '.github/**' + - 'Cargo.toml' - 'crates/**' pull_request: paths: - '.github/**' + - 'Cargo.toml' - 'crates/**' env: diff --git a/.github/workflows/spell-checking.yml b/.github/workflows/spell-checking.yml index 8dd830da..0eddd97e 100644 --- a/.github/workflows/spell-checking.yml +++ b/.github/workflows/spell-checking.yml @@ -3,7 +3,7 @@ name: Spell Checker on: push: branches: - - main + - 'main' pull_request: diff --git a/.github/workflows/typescript.yml b/.github/workflows/typescript.yml index b124f67f..7778357d 100644 --- a/.github/workflows/typescript.yml +++ b/.github/workflows/typescript.yml @@ -3,13 +3,21 @@ name: Typescript CI on: push: branches: - - main + - 'main' paths: + # ⬇ Keep paths in sync with `ci-documentation.yml` - '.github/**' + - '*' + - '!Cargo.toml' + # ⬆ Keep paths in sync with `ci-documentation.yml` - 'packages/**' pull_request: paths: + # ⬇ Keep paths in sync with `ci-documentation.yml` - '.github/**' + - '*' + - '!Cargo.toml' + # ⬆ Keep paths in sync with `ci-documentation.yml` - 'packages/**' jobs: