-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpatch_workflow.sh
More file actions
executable file
·44 lines (40 loc) · 1.34 KB
/
Copy pathpatch_workflow.sh
File metadata and controls
executable file
·44 lines (40 loc) · 1.34 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
#!/bin/bash
# 1. Add tags trigger
sed -i '' -e '/branches:/i\
tags:\
- "v*"\
' /Users/aditya/Development/EchoMusic/.github/workflows/android-release.yml
# 2. Append the release job
cat << 'INNER_EOF' >> /Users/aditya/Development/EchoMusic/.github/workflows/android-release.yml
create-github-release:
name: Create GitHub Release
runs-on: ubuntu-latest
needs: [build-full-release, build-foss-release]
# Only run this job if a tag was pushed (e.g. v1.0.0)
if: startsWith(github.ref, 'refs/tags/v')
permissions:
contents: write
steps:
- name: Download Full Release APK
uses: actions/download-artifact@v4
with:
name: app-full-release
path: release-artifacts/full
- name: Download FOSS Release APK
uses: actions/download-artifact@v4
with:
name: app-foss-release
path: release-artifacts/foss
- name: Create Release and Upload Assets
uses: softprops/action-gh-release@v2
with:
# Automatically uses the pushed tag
name: Echo Music ${{ github.ref_name }}
draft: false
prerelease: false
generate_release_notes: true
files: |
release-artifacts/full/*.apk
release-artifacts/foss/*.apk
INNER_EOF
chmod +x patch_workflow.sh && ./patch_workflow.sh