Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c77667d

Browse files
ci(workflows): minor fixes and updates
1 parent 6efc687 commit c77667d

File tree

4 files changed

+66
-20
lines changed

4 files changed

+66
-20
lines changed

.github/workflows/release-notifier-moonlight.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ jobs:
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: discord
18-
uses: sarisia/actions-status-discord@v1 # https://github.com/sarisia/actions-status-discord
18+
uses: sarisia/actions-status-discord@v1
1919
with:
20-
webhook: ${{ secrets.DISCORD_RELEASE_WEBHOOK_MOONLIGHT }}
20+
avatar_url: ${{ vars.ORG_LOGO_URL }}256
21+
color: 0x${{ vars.COLOR_HEX_GREEN }}
22+
description: ${{ github.event.release.body }}
2123
nodetail: true
2224
nofail: false
23-
username: ${{ secrets.DISCORD_USERNAME }}
24-
avatar_url: ${{ secrets.ORG_LOGO_URL }}
2525
title: ${{ github.event.repository.name }} ${{ github.ref_name }} Released
26-
description: ${{ github.event.release.body }}
27-
color: 0xFF4500
26+
username: ${{ secrets.DISCORD_USERNAME }}
27+
webhook: ${{ secrets.DISCORD_RELEASE_WEBHOOK_MOONLIGHT }}

.github/workflows/update-flathub-repo.yml

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ name: Update flathub repo
99

1010
on:
1111
release:
12-
types: [released]
12+
types:
13+
- released
1314

1415
concurrency:
1516
group: "${{ github.workflow }}-${{ github.event.release.tag_name }}"
@@ -114,7 +115,7 @@ jobs:
114115
out-file-path: "flathub/${{ env.FLATHUB_PKG }}"
115116
extract: true
116117

117-
- name: Delete arhive
118+
- name: Delete archive
118119
if: >-
119120
steps.check-label.outputs.hasTopic == 'true' &&
120121
steps.check-release.outputs.isLatestRelease == 'true'
@@ -172,6 +173,7 @@ jobs:
172173
git checkout $main_commit
173174
174175
- name: Create/Update Pull Request
176+
id: create-pr
175177
if: >-
176178
steps.check-label.outputs.hasTopic == 'true' &&
177179
steps.check-release.outputs.isLatestRelease == 'true' &&
@@ -185,3 +187,20 @@ jobs:
185187
delete-branch: true
186188
title: "chore: Update ${{ env.FLATHUB_PKG }} to ${{ github.event.release.tag_name }}"
187189
body: ${{ github.event.release.body }}
190+
191+
- name: Automerge PR
192+
env:
193+
GH_TOKEN: ${{ secrets.GH_BOT_TOKEN }}
194+
if: >-
195+
steps.check-label.outputs.hasTopic == 'true' &&
196+
steps.check-release.outputs.isLatestRelease == 'true' &&
197+
fromJson(steps.download.outputs.downloaded_files)[0]
198+
run: |
199+
gh \
200+
pr \
201+
merge \
202+
--auto \
203+
--delete-branch \
204+
--repo "flathub/${{ env.FLATHUB_PKG }}" \
205+
--squash \
206+
"${{ steps.create-pr.outputs.pull-request-number }}"

.github/workflows/update-pacman-repo.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,16 @@ jobs:
8787
out-file-path: "pkgbuilds/${{ steps.prep.outputs.pkg_name }}"
8888
extract: true
8989

90+
- name: Remove pkg.tar.gz
91+
if: >-
92+
steps.check-label.outputs.hasTopic == 'true' &&
93+
steps.check-release.outputs.isLatestRelease == 'true' &&
94+
fromJson(steps.download.outputs.downloaded_files)[0]
95+
run: |
96+
rm -f "pkgbuilds/${{ steps.prep.outputs.pkg_name }}"
97+
9098
- name: Create/Update Pull Request
99+
id: create-pr
91100
if: >-
92101
steps.check-label.outputs.hasTopic == 'true' &&
93102
steps.check-release.outputs.isLatestRelease == 'true' &&
@@ -105,3 +114,19 @@ jobs:
105114
labels: |
106115
auto-approve
107116
auto-merge
117+
118+
- name: Automerge PR
119+
env:
120+
GH_TOKEN: ${{ secrets.GH_BOT_TOKEN }}
121+
if: >-
122+
steps.check-label.outputs.hasTopic == 'true' &&
123+
steps.check-release.outputs.isLatestRelease == 'true' &&
124+
fromJson(steps.download.outputs.downloaded_files)[0]
125+
run: |
126+
gh \
127+
pr \
128+
merge \
129+
--auto \
130+
--delete-branch \
131+
--squash \
132+
"${{ steps.create-pr.outputs.pull-request-number }}"

scripts/linux_build.sh

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ shift $((OPTIND -1))
8585
# dependencies array to build out
8686
dependencies=()
8787

88-
function add_debain_based_deps() {
88+
function add_debian_based_deps() {
8989
dependencies+=(
9090
"bison" # required if we need to compile doxygen
9191
"build-essential"
@@ -128,8 +128,8 @@ function add_debain_based_deps() {
128128
fi
129129
}
130130

131-
function add_debain_deps() {
132-
add_debain_based_deps
131+
function add_debian_deps() {
132+
add_debian_based_deps
133133
dependencies+=(
134134
"libayatana-appindicator3-dev"
135135
)
@@ -141,7 +141,7 @@ function add_ubuntu_deps() {
141141
${sudo_cmd} add-apt-repository ppa:ubuntu-toolchain-r/test -y
142142
fi
143143

144-
add_debain_based_deps
144+
add_debian_based_deps
145145
dependencies+=(
146146
"libappindicator3-dev"
147147
)
@@ -297,12 +297,12 @@ function run_install() {
297297
$package_update_command
298298

299299
if [ "$distro" == "debian" ]; then
300-
add_debain_deps
300+
add_debian_deps
301301
elif [ "$distro" == "ubuntu" ]; then
302302
add_ubuntu_deps
303303
elif [ "$distro" == "fedora" ]; then
304304
add_fedora_deps
305-
${sudo_cmd} dnf group install "Development Tools" -y
305+
${sudo_cmd} dnf group install "$dev_tools_group" -y
306306
fi
307307

308308
# Install the dependencies
@@ -438,24 +438,26 @@ if grep -q "Debian GNU/Linux 12 (bookworm)" /etc/os-release; then
438438
cuda_build="525.60.13"
439439
gcc_version="12"
440440
nvm_node=0
441-
elif grep -q "PLATFORM_ID=\"platform:f39\"" /etc/os-release; then
441+
elif grep -q "PLATFORM_ID=\"platform:f40\"" /etc/os-release; then
442442
distro="fedora"
443-
version="39"
443+
version="40"
444444
package_update_command="${sudo_cmd} dnf update -y"
445445
package_install_command="${sudo_cmd} dnf install -y"
446-
cuda_version="12.4.0"
447-
cuda_build="550.54.14"
446+
cuda_version=
447+
cuda_build=
448448
gcc_version="13"
449449
nvm_node=0
450-
elif grep -q "PLATFORM_ID=\"platform:f40\"" /etc/os-release; then
450+
dev_tools_group="Development Tools"
451+
elif grep -q "PLATFORM_ID=\"platform:f41\"" /etc/os-release; then
451452
distro="fedora"
452-
version="40"
453+
version="41"
453454
package_update_command="${sudo_cmd} dnf update -y"
454455
package_install_command="${sudo_cmd} dnf install -y"
455456
cuda_version=
456457
cuda_build=
457458
gcc_version="13"
458459
nvm_node=0
460+
dev_tools_group="development-tools"
459461
elif grep -q "Ubuntu 22.04" /etc/os-release; then
460462
distro="ubuntu"
461463
version="22.04"

0 commit comments

Comments
 (0)