Skip to content

Commit

Permalink
ci: deduplicate workflows runs
Browse files Browse the repository at this point in the history
  • Loading branch information
PedroTroller committed Feb 26, 2024
1 parent 4301776 commit 2450ba9
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 3 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/bc.yml → .github/workflows/bc.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
on: [push, pull_request]
---
name: Roave

on: workflow_call

jobs:
roave_bc_check:
name: BC Check
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
on: [push, pull_request]
---
name: Static analysis

on: workflow_call

jobs:
phpstan:
name: PHPStan
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/pull-request.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
name: Pull-Request

on: pull_request

jobs:
bc:
uses: ./.github/workflows/bc.yaml

tests:
uses: ./.github/workflows/tests.yaml
14 changes: 14 additions & 0 deletions .github/workflows/push.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
name: Push

on:
push:
branches:
- master

jobs:
bc:
uses: ./.github/workflows/bc.yaml

tests:
uses: ./.github/workflows/tests.yaml
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml → .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---
name: Tests
on: [push, pull_request]

on: workflow_call

jobs:

Expand Down

0 comments on commit 2450ba9

Please sign in to comment.