-
-
Notifications
You must be signed in to change notification settings - Fork 2
72 lines (63 loc) · 1.92 KB
/
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
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
name: Push Release
on: workflow_dispatch
jobs:
release:
runs-on: macos-latest
steps:
- name: Checkout latest repository commit
uses: actions/[email protected]
with:
show-progress: false
- id: get-tag
name: Fetches latest release tag
shell: bash
run: |
LATEST_TAG="$(grep -m 1 -o '## \[.*\]' Changelog.md | awk -F'[][]' '{print $2}')"
echo "TAG=$LATEST_TAG" >> "$GITHUB_ENV"
- name: Make file executable
run: |
chmod +x UXTU4Mac/Assets/ryzenadj
chmod +x UXTU4Mac/UXTU4Mac.command
- name: Zip folder
run: |
zip -r UXTU4Mac.zip UXTU4Mac
env:
TAG: ${{ env.TAG }}
- name: Install create-dmg
run: |
brew install create-dmg
- name: Create symbolic link
run: |
ln -s /Applications UXTU4Mac/Applications
- name: Create dmg
run: |
create-dmg \
--volname "UXTU4Mac" \
--volicon "Img/Logo.png" \
--window-pos 200 120 \
--window-size 800 400 \
--icon-size 100 \
--icon UXTU4Mac 200 190 \
--hide-extension UXTU4Mac \
--app-drop-link 600 185 \
--hdiutil-quiet \
UXTU4Mac.dmg UXTU4Mac/
- id: generate-notes
name: Generate Release Notes
shell: bash
run: |
BODY="$(sed -n "/## \[$TAG\]/,/## \[/p" Changelog.md | sed -e '1,2d;$d')"
echo "$BODY" > ${{ github.workspace }}-RELEASE_NOTES.txt
env:
TAG: ${{ env.TAG }}
- name: Create release
uses: softprops/[email protected]
with:
name: v${{ env.TAG }}
tag_name: ${{ env.TAG }}
body_path: ${{ github.workspace }}-RELEASE_NOTES.txt
files: |
UXTU4Mac.zip
UXTU4Mac.dmg
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}