diff --git a/.github/workflows/build-test-and-sonar.yml b/.github/workflows/build-test-and-sonar.yml index 072325b3..3e323dda 100644 --- a/.github/workflows/build-test-and-sonar.yml +++ b/.github/workflows/build-test-and-sonar.yml @@ -13,17 +13,25 @@ on: pull_request: # run pipeline on merge queue merge_group: + # run pipeline from another workflow + workflow_call: + inputs: + create_release: + type: boolean + description: Create a (pre-)release when CI passes + default: false + required: false # run this workflow manually from the Actions tab workflow_dispatch: inputs: create_release: type: boolean description: Create a (pre-)release when CI passes - default: true + default: false required: true concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.ref }}-main cancel-in-progress: true jobs: diff --git a/.github/workflows/check-blocking-labels.yml b/.github/workflows/check-blocking-labels.yml index b571c092..09f5c65b 100644 --- a/.github/workflows/check-blocking-labels.yml +++ b/.github/workflows/check-blocking-labels.yml @@ -19,7 +19,7 @@ on: workflow_dispatch: concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.ref }}-blocking-labels cancel-in-progress: true jobs: diff --git a/.github/workflows/check-code-quality.yml b/.github/workflows/check-code-quality.yml index d18012a7..cfc25e1c 100644 --- a/.github/workflows/check-code-quality.yml +++ b/.github/workflows/check-code-quality.yml @@ -13,9 +13,11 @@ on: pull_request: # run pipeline on merge queue merge_group: + # run pipeline from another workflow + workflow_call: concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.ref }}-code-quality cancel-in-progress: true jobs: diff --git a/.github/workflows/citations.yml b/.github/workflows/citations.yml index 269d7d94..ed4afb69 100644 --- a/.github/workflows/citations.yml +++ b/.github/workflows/citations.yml @@ -12,16 +12,17 @@ on: paths: - CITATION.cff - .github/workflows/citations.yml - pull_request: paths: - CITATION.cff - .github/workflows/citations.yml - + # run pipeline from another workflow + workflow_call: + # run this workflow manually from the Actions tab workflow_dispatch: concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.ref }}-citations cancel-in-progress: true jobs: diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml new file mode 100644 index 00000000..4b2a28fa --- /dev/null +++ b/.github/workflows/nightly.yml @@ -0,0 +1,32 @@ +# SPDX-FileCopyrightText: Contributors to the Power Grid Model project +# +# SPDX-License-Identifier: MPL-2.0 + +name: Nightly build + +# Controls when the workflow will run +on: + workflow_dispatch: + schedule: + - cron: "0 2 * * *" # Based on UTC time + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }}-nightly + cancel-in-progress: true + +jobs: + main: + uses: "./.github/workflows/build-test-and-sonar.yml" + permissions: + contents: write + with: + create_release: false + + check-code-quality: + uses: "./.github/workflows/check-code-quality.yml" + + reuse-compliance: + uses: "./.github/workflows/reuse-compliance.yml" + + citations: + uses: "./.github/workflows/citations.yml" diff --git a/.github/workflows/reuse-compliance.yml b/.github/workflows/reuse-compliance.yml index 7ce4c335..2231f786 100644 --- a/.github/workflows/reuse-compliance.yml +++ b/.github/workflows/reuse-compliance.yml @@ -13,9 +13,13 @@ on: pull_request: # run pipeline on merge queue merge_group: + # run pipeline from another workflow + workflow_call: + # run this workflow manually from the Actions tab + workflow_dispatch: concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.ref }}-reuse-compliance cancel-in-progress: true jobs: