-
-
Notifications
You must be signed in to change notification settings - Fork 0
116 lines (93 loc) · 3.04 KB
/
release.yml
File metadata and controls
116 lines (93 loc) · 3.04 KB
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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
# This workflow is provided via the organization template repository
#
# https://github.com/nextcloud/.github
# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization
name: Release
on:
push:
branches: [master]
pull_request:
branches: [master]
permissions:
contents: write
issues: write
pull-requests: write
concurrency:
group: release-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
release:
name: Release
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
tag_name: ${{ steps.release.outputs.tag_name }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download builds
uses: actions/download-artifact@v4
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.RELEASE_PLEASE_TOKEN }}
build:
name: App Store Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get php version
id: versions
uses: icewind1991/nextcloud-version-matrix@v1
- name: Set up php${{ steps.versions.outputs.php-available }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ steps.versions.outputs.php-available }}
extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite
coverage: none
ini-file: development
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build App
run: |
npm i -g pnpm
make && make appstore
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: jukebox.tar.gz
path: build/artifacts/appstore/jukebox.tar.gz
upload:
runs-on: ubuntu-latest
name: Upload Release Artifacts
needs: [build, release]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download Artifacts
uses: actions/download-artifact@v4
with:
name: jukebox.tar.gz
- name: Prepare Artifact Upload
run: test -f "$PWD/jukebox.tar.gz"
- name: Upload to Release
if: ${{ needs.release.outputs.release_created }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
mv jukebox.tar.gz "jukebox-${{ needs.release.outputs.tag_name }}.tar.gz"
gh release upload ${{ needs.release.outputs.tag_name }} jukebox-${{ needs.release.outputs.tag_name }}.tar.gz
release-nextcloud:
name: Release to Nextcloud Apps
runs-on: ubuntu-latest
needs: [build, release, upload]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Release to Nextcloud Apps
if: ${{ needs.release.outputs.release_created }}
env:
NEXTCLOUD_API_TOKEN: ${{ secrets.NEXTCLOUD_API_TOKEN }}
run: |
make release