-
Notifications
You must be signed in to change notification settings - Fork 0
91 lines (82 loc) · 2 KB
/
core.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
name: Core
on:
push:
branches:
- master
pull_request:
branches:
- '**'
permissions:
contents: read
jobs:
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Default init
uses: ./
with:
key: foo
- name: Path init
uses: ./
with:
key: bar
path: here
- name: Test default path
shell: bash
run: |
if [ "$(cat ~/.ssh/id_rsa)" != "foo" ]; then
exit 1
fi
- name: Test custom path
shell: bash
run: |
if [ "$(cat here)" != "bar" ]; then
exit 1
fi
release:
name: Changelog & Release
runs-on: ubuntu-latest
needs:
- test
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- name: Parse
id: parse
uses: alorel-actions/semantic-release-lite@v0
with:
minor-types: |
feat: Features
patch-types: |
fix: Bug Fixes
deps: Dependency updates
perf: Performance
trivial-types: |
chore: Maintenance
ci: CI & Build
build: CI & Build
refactor: Refactors
docs: Documentation
- name: Release
uses: ./.github/actions/release
if: ${{ steps.parse.outputs.should-release && github.ref == 'refs/heads/master' }}
with:
major: ${{ steps.parse.outputs.next-version-major }}
minor: ${{ steps.parse.outputs.next-version-minor }}
patch: ${{ steps.parse.outputs.next-version-patch }}
changelog: ${{ steps.parse.outputs.changelog }}
issues-closed: ${{ steps.parse.outputs.issues-closed }}