-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (32 loc) · 876 Bytes
/
on-main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: On main
on:
push:
branches:
- main
paths-ignore:
- ".version" # all except if only this file changes and nothing else.
jobs:
get-cl-entries:
name: Get changelog entries
runs-on: ubuntu-latest
outputs:
entries: ${{ steps.get-number-of-entries.outputs.entries }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Get number of entries
id: get-number-of-entries
run: |
number=$(ls ./changelog/pending | wc -l)
echo "entries=${number}" >> $GITHUB_OUTPUT
bump-version-pr:
name: Bump version PR
needs: [get-cl-entries]
if: ${{ needs.get-cl-entries.outputs.entries >= 3 }}
uses: ./.github/workflows/bump-version-pr.yml
permissions:
contents: write
pull-requests: write
with:
ref: ${{ github.sha }}
secrets: inherit