Skip to content

Commit

Permalink
Merge pull request #1821 from lf-lang/fix-workflow-dispatch
Browse files Browse the repository at this point in the history
Changes to workflow dispatch
  • Loading branch information
cmnrd authored Jun 7, 2023
2 parents ebed89e + 1be54f0 commit b9a6383
Show file tree
Hide file tree
Showing 7 changed files with 2 additions and 43 deletions.
1 change: 1 addition & 0 deletions .github/workflows/all-misc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- master
pull_request:
types: [synchronize, opened, reopened, ready_for_review, converted_to_draft]
merge_group:

env:
# 2020.11
Expand Down
11 changes: 1 addition & 10 deletions .github/workflows/all-targets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- master
pull_request:
types: [synchronize, opened, reopened, ready_for_review, converted_to_draft]
merge_group:

env:
# 2020.11
Expand All @@ -23,36 +24,26 @@ jobs:

c:
uses: ./.github/workflows/only-c.yml
with:
all: true
needs: check-diff
if: ${{ !github.event.pull_request.draft || needs.check-diff.outputs.changed-c == 1 }}

cpp:
uses: ./.github/workflows/only-cpp.yml
with:
all: true
needs: check-diff
if: ${{ !github.event.pull_request.draft || needs.check-diff.outputs.changed-cpp == 1 }}

py:
uses: ./.github/workflows/only-py.yml
with:
all: true
needs: check-diff
if: ${{ !github.event.pull_request.draft || needs.check-diff.outputs.changed-py == 1 }}

rs:
uses: ./.github/workflows/only-rs.yml
with:
all: true
needs: check-diff
if: ${{ !github.event.pull_request.draft || needs.check-diff.outputs.changed-rs == 1 }}

ts:
uses: ./.github/workflows/only-ts.yml
with:
all: true
needs: check-diff
if: ${{ !github.event.pull_request.draft || needs.check-diff.outputs.changed-ts == 1 }}

Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/only-c.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ name: C
on:
workflow_dispatch:
workflow_call:
inputs:
all:
default: true
type: boolean

env:
# 2020.11
Expand All @@ -19,33 +15,28 @@ concurrency:
jobs:
# Run the C integration tests.
default:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/c-tests.yml
with:
all-platforms: ${{ !github.event.pull_request.draft }}

# Run the C benchmark tests.
benchmarking:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: lf-lang/benchmarks-lingua-franca/.github/workflows/benchmark-tests.yml@gradle
with:
target: "C"

# Run the C Arduino integration tests.
arduino:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/c-arduino-tests.yml
with:
all-platforms: ${{ !github.event.pull_request.draft }}

# Run the C Zephyr integration tests.
zephyr:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/c-zephyr-tests.yml

# Run the CCpp integration tests.
ccpp:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/c-tests.yml
with:
use-cpp: true
Expand Down
7 changes: 0 additions & 7 deletions .github/workflows/only-cpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ name: C++
on:
workflow_dispatch:
workflow_call:
inputs:
all:
default: true
type: boolean

env:
# 2020.11
Expand All @@ -19,19 +15,16 @@ concurrency:
jobs:
# Run the C++ benchmark tests.
cpp-benchmark-tests:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: lf-lang/benchmarks-lingua-franca/.github/workflows/benchmark-tests.yml@gradle
with:
target: "Cpp"

# Run the C++ integration tests.
cpp-tests:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/cpp-tests.yml
with:
all-platforms: ${{ !github.event.pull_request.draft }}

# Run the C++ integration tests on ROS2.
cpp-ros2-tests:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/cpp-ros2-tests.yml
5 changes: 0 additions & 5 deletions .github/workflows/only-py.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ name: Python
on:
workflow_dispatch:
workflow_call:
inputs:
all:
default: true
type: boolean

env:
# 2020.11
Expand All @@ -20,6 +16,5 @@ jobs:
# Run the Python integration tests.
py-tests:
uses: ./.github/workflows/py-tests.yml
if: ${{ inputs.all || github.event.pull_request.draft }}
with:
all-platforms: ${{ !github.event.pull_request.draft }}
6 changes: 0 additions & 6 deletions .github/workflows/only-rs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ name: Rust
on:
workflow_dispatch:
workflow_call:
inputs:
all:
default: true
type: boolean

env:
# 2020.11
Expand All @@ -19,14 +15,12 @@ concurrency:
jobs:
# Run the Rust integration tests.
rs-tests:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/rs-tests.yml
with:
all-platforms: ${{ !github.event.pull_request.draft }}

# Run the Rust benchmark tests.
rs-benchmark-tests:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: lf-lang/benchmarks-lingua-franca/.github/workflows/benchmark-tests.yml@gradle
with:
target: "Rust"
6 changes: 0 additions & 6 deletions .github/workflows/only-ts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ name: TypeScript
on:
workflow_dispatch:
workflow_call:
inputs:
all:
default: true
type: boolean

env:
# 2020.11
Expand All @@ -19,14 +15,12 @@ concurrency:
jobs:
# Run the TypeScript benchmark tests.
benchmarking:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: lf-lang/benchmarks-lingua-franca/.github/workflows/benchmark-tests.yml@gradle
with:
target: "TS"

# Run the TypeScript integration tests.
ts-tests:
if: ${{ inputs.all || github.event.pull_request.draft }}
uses: ./.github/workflows/ts-tests.yml
with:
all-platforms: ${{ !github.event.pull_request.draft }}

0 comments on commit b9a6383

Please sign in to comment.