diff --git a/.github/workflows/beta-deployment.yml b/.github/workflows/beta-deployment.yml index a00ca53a..3cbe893f 100644 --- a/.github/workflows/beta-deployment.yml +++ b/.github/workflows/beta-deployment.yml @@ -14,10 +14,20 @@ on: - main workflow_dispatch: +concurrency: + group: ${{ github.workflow }} + cancel-in-progress: false + jobs: buildandtest: name: Build and Test uses: ./.github/workflows/build-and-test.yml + permissions: + contents: read + secrets: inherit + staticanaylsis: + name: Static Analysis + uses: ./.github/workflows/static_analysis.yml permissions: security-events: write actions: read diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.yml index a64997c4..0c7d6c89 100644 --- a/.github/workflows/build-and-test.yml +++ b/.github/workflows/build-and-test.yml @@ -13,39 +13,11 @@ on: workflow_dispatch: workflow_call: +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: - reuse_action: - name: REUSE Compliance Check - uses: StanfordBDHG/.github/.github/workflows/reuse.yml@v2 - permissions: - contents: read - swiftlint: - name: SwiftLint - uses: StanfordBDHG/.github/.github/workflows/swiftlint.yml@v2 - permissions: - contents: read - periphery: - name: Periphery - uses: StanfordSpezi/.github/.github/workflows/periphery.yml@v2 - permissions: - contents: read - with: - runsonlabels: '["macOS", "self-hosted"]' - markdownlinkcheck: - name: Markdown Link Check - uses: StanfordBDHG/.github/.github/workflows/markdown-link-check.yml@v2 - permissions: - contents: read - codeql: - name: CodeQL - uses: StanfordSpezi/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2 - permissions: - security-events: write - actions: read - contents: read - with: - codeql: true - fastlanelane: codeql buildandtest: name: Build and Test uses: StanfordSpezi/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2 diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml new file mode 100644 index 00000000..3c05eaff --- /dev/null +++ b/.github/workflows/static-analysis.yml @@ -0,0 +1,52 @@ +# +# This source file is part of the Stanford Spezi open source project +# +# SPDX-FileCopyrightText: 2022 Stanford University and the project authors (see CONTRIBUTORS.md) +# +# SPDX-License-Identifier: MIT +# + +name: Static Analysis + +on: + pull_request: + workflow_dispatch: + workflow_call: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + reuse_action: + name: REUSE Compliance Check + uses: StanfordBDHG/.github/.github/workflows/reuse.yml@v2 + permissions: + contents: read + swiftlint: + name: SwiftLint + uses: StanfordBDHG/.github/.github/workflows/swiftlint.yml@v2 + permissions: + contents: read + periphery: + name: Periphery + uses: StanfordSpezi/.github/.github/workflows/periphery.yml@v2 + permissions: + contents: read + with: + runsonlabels: '["macOS", "self-hosted"]' + markdownlinkcheck: + name: Markdown Link Check + uses: StanfordBDHG/.github/.github/workflows/markdown-link-check.yml@v2 + permissions: + contents: read + codeql: + name: CodeQL + uses: StanfordSpezi/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2 + permissions: + security-events: write + actions: read + contents: read + with: + codeql: true + fastlanelane: codeql