-
Notifications
You must be signed in to change notification settings - Fork 17
91 lines (80 loc) · 2.42 KB
/
develop.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: Build Snapshot
on:
push:
paths-ignore:
- 'README.md'
branches: [ "develop" ]
pull_request:
branches: [ "develop" ]
concurrency:
group: ${{ github.name }}-${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
id-token: write
contents: read
checks: write # required for test-reporter
jobs:
build:
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- uses: ./.github/workflows/actions/build
- uses: ./.github/workflows/actions/doc
test:
needs: [ build ]
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- uses: ./.github/workflows/actions/test
create-swift-package:
needs: [ build, test]
if: github.ref == 'refs/heads/develop'
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- uses: ./.github/workflows/actions/createSwiftPackage
with:
version: "develop"
deploy-swift-package-snapshot:
needs: [create-swift-package]
if: github.ref == 'refs/heads/develop'
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- uses: ./.github/workflows/actions/deploySwiftPackage
with:
branch: "develop"
token: ${{ secrets.PAT }}
deploy-snapshot:
needs: [ test ]
if: github.ref == 'refs/heads/develop'
runs-on: macos-13
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
fetch-tags: true
fetch-depth: 0
- uses: ./.github/workflows/actions/prepare
- name: Setup git-mkver
uses: cperezabo/[email protected]
with:
version: "1.3.0"
- name: Generate version
run: |
echo "tags: $(git tag)"
echo "log:"
git log -n 3
git status
export VERSION=$(git mkver next --pre-release)
echo "this is version: $VERSION"
echo "VERSION=$VERSION" >> "$GITHUB_ENV"
- name: Publish
run: ./gradlew publishAllPublicationsToSonatypeRepository -Pversion=$VERSION --max-workers 1
env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
SONATYPE_STAGING_PROFILE_ID: ${{ secrets.SONATYPE_STAGING_PROFILE_ID }}
SIGNING_KEY_ID: ${{ secrets.SIGNING_KEY_ID }}
SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
SIGNING_KEY_PASSWORD: ${{ secrets.SIGNING_KEY_PASSWORD }}