Skip to content

Commit

Permalink
use reusable workflow to disentangle manuall and automatic triggering
Browse files Browse the repository at this point in the history
  • Loading branch information
JuliaSprenger committed Jun 23, 2023
1 parent 20bcfdf commit 904fdc1
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 21 deletions.
26 changes: 5 additions & 21 deletions .github/workflows/io-test.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,10 @@
name: NeoIoTest

on:
pull_request:
branches: [master]
types: [synchronize, opened, reopened, ready_for_review]
inputs:
os: 'ubuntu-latest'

# run checks on any change of master, including merge of PRs
push:
branches: [master]

workflow_dispatch:
inputs:
os:
description: 'The operating system to run the tests on'
required: True
default: 'ubuntu-latest'
type: choice
options:
- macos-latest
- windows-latest
workflow_call:
inputs:
os:
required: true
type: string

concurrency: # Cancel previous workflows on the same pull request
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/io-test_dispatch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: NeoIoTest-manual-trigger

workflow_dispatch:
inputs:
os:
description: 'The operating system to run the tests on'
required: True
default: 'ubuntu-latest'
type: choice
options:
- macos-latest
- windows-latest

jobs:
call-iotests:
uses: Neuralensemble/python-neo/.github/workflows/io-test.yml@main
with:
os: ${{ inputs.os }}
16 changes: 16 additions & 0 deletions .github/workflows/io-test_trigger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: NeoIoTest-automatic-trigger

on:
pull_request:
branches: [master]
types: [synchronize, opened, reopened, ready_for_review]

# run checks on any change of master, including merge of PRs
push:
branches: [master]

jobs:
call-iotests:
uses: Neuralensemble/python-neo/.github/workflows/io-test.yml@main
with:
os: ubuntu-latest

0 comments on commit 904fdc1

Please sign in to comment.