Skip to content

Commit 9432c65

Browse files
author
Carlos Fortes
committed
Merge branch 'master' into feature/endgame-mode
2 parents 9bb34be + 146fa9a commit 9432c65

14 files changed

Lines changed: 279 additions & 102 deletions

.github/workflows/packaging.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,12 @@ jobs:
318318
runs-on: macos-15
319319
steps:
320320
- uses: actions/checkout@v6
321+
with:
322+
# Need tags so `git describe --tags` in the .dmg name resolves
323+
# to the release tag (aMule-3.0.1-macOS-universal2.dmg). Without
324+
# this the checkout is shallow with no tags and describe falls
325+
# back to --always (the short SHA), producing a SHA-named dmg.
326+
fetch-depth: 0
321327
- uses: actions/download-artifact@v8
322328
with:
323329
name: macos-app-arm64

.github/workflows/release.yml

Lines changed: 94 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,28 @@
1-
# Release — tag-triggered workflow that runs the full packaging matrix
2-
# and assembles a draft GitHub Release with the artifacts attached.
1+
# Release — produces a draft GitHub Release with every platform's
2+
# artifact attached. Two entry points, both ending in the same draft:
33
#
4-
# Pushing a release-like tag fires the packaging matrix as a reusable
5-
# workflow, then a release job collects every platform's final artifact
6-
# and creates a draft Release on the repository the tag was pushed to.
4+
# 1. One-click (workflow_dispatch): a maintainer opens Actions →
5+
# Release → Run workflow, picks the branch to release from, and
6+
# types a version (e.g. 3.0.1). The prepare-tag job creates and
7+
# pushes that tag at the tip of the selected branch if it doesn't
8+
# already exist, then the full packaging matrix runs and the draft
9+
# is assembled. No local `git tag` / `git push` needed. Re-running
10+
# with an existing tag just re-assembles the assets (retry path).
11+
#
12+
# 2. Push a release-like tag from a local checkout — same downstream
13+
# flow, kept for scripted / habitual taggers.
714
#
815
# Tag filter: digit-leading tags (aMule's convention — 2.3.3, 2.4.0-rc1,
916
# 3.0-beta) plus optional v-prefix (v2.4.0) for compatibility. Excludes
1017
# branch-backup / topic tags like `backup/*`, `per-peer-cap-fix`, etc.
1118
#
12-
# Test on a fork by pushing a tag like `0.0.0-fork-test` — the draft
13-
# Release lands on the fork's Releases page, not upstream.
19+
# Test on a fork by dispatching (or pushing) a version like
20+
# `0.0.0-fork-test` — the tag and the draft Release land on the fork,
21+
# not upstream.
22+
#
23+
# Before the draft is created, the release job asserts that all ten
24+
# expected platform assets are present, so a half-built matrix can never
25+
# silently produce a draft that's missing a platform.
1426
#
1527
# Output is always a draft so a maintainer can review the asset list
1628
# and edit the auto-generated notes before publishing.
@@ -24,23 +36,59 @@ on:
2436
- 'v[0-9]*'
2537
workflow_dispatch:
2638
inputs:
27-
tag:
39+
version:
2840
description: >-
29-
Tag to release. Must already exist as a git tag on the repo.
30-
Use this to retry asset assembly without re-tagging.
41+
Version to release, e.g. 3.0.1 or 3.1.0-rc1. Created and
42+
pushed as a tag at the tip of the branch selected above if it
43+
doesn't already exist. Re-run with an existing version to
44+
retry asset assembly without re-tagging.
3145
required: true
3246
type: string
3347

3448
permissions:
3549
contents: write
3650

3751
jobs:
52+
# One-click entry point: turn the dispatched version into a real tag
53+
# so the rest of the pipeline (which keys off git tags for versioning)
54+
# behaves identically to the push-a-tag path. On the push trigger this
55+
# job is a trivial no-op — the tag already exists — but it still runs
56+
# so build/source-bundle can depend on it unconditionally.
57+
prepare-tag:
58+
name: Create tag
59+
runs-on: ubuntu-latest
60+
steps:
61+
- uses: actions/checkout@v6
62+
with:
63+
fetch-depth: 0
64+
- name: Create and push tag if missing
65+
if: github.event_name == 'workflow_dispatch'
66+
env:
67+
TAG: ${{ inputs.version }}
68+
run: |
69+
set -euo pipefail
70+
if git rev-parse -q --verify "refs/tags/${TAG}" >/dev/null; then
71+
echo "Tag ${TAG} already exists — re-assembling assets, not re-tagging."
72+
exit 0
73+
fi
74+
git config user.name "github-actions[bot]"
75+
git config user.email "github-actions[bot]@users.noreply.github.com"
76+
# Annotated tag at the dispatched commit (tip of the selected
77+
# branch). fetch-depth:0 above means git describe in the build
78+
# jobs resolves this to an exact-match tag, so artifacts are
79+
# versioned cleanly (aMule-3.0.1-... not aMule-...-gabc123).
80+
git tag -a "${TAG}" -m "aMule ${TAG}"
81+
git push origin "refs/tags/${TAG}"
82+
echo "Created and pushed tag ${TAG} at ${GITHUB_SHA}."
83+
3884
build:
3985
name: Build artifacts
86+
needs: prepare-tag
4087
uses: ./.github/workflows/packaging.yml
4188

4289
source-bundle:
4390
name: Build source bundle with pre-rendered manpages
91+
needs: prepare-tag
4492
runs-on: ubuntu-latest
4593
steps:
4694
- uses: actions/checkout@v6
@@ -51,7 +99,7 @@ jobs:
5199
id: tag
52100
run: |
53101
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
54-
echo "tag=${{ inputs.tag }}" >> "$GITHUB_OUTPUT"
102+
echo "tag=${{ inputs.version }}" >> "$GITHUB_OUTPUT"
55103
else
56104
echo "tag=${{ github.ref_name }}" >> "$GITHUB_OUTPUT"
57105
fi
@@ -156,13 +204,47 @@ jobs:
156204
- name: List artifacts
157205
run: ls -la dist/
158206

207+
- name: Verify all platform artifacts are present
208+
# Belt-and-suspenders manifest check. The build matrix uses
209+
# fail-fast:false and this job `needs: [build, source-bundle]`,
210+
# so a failed platform already blocks the draft via `needs` —
211+
# but that surfaces as a generic "dependency failed". This step
212+
# instead names exactly which asset is missing, and guards
213+
# against the subtler case where a platform's upload succeeded
214+
# with an unexpected filename (so the glob below finds nothing).
215+
run: |
216+
set -euo pipefail
217+
fail=0
218+
check() {
219+
local label="$1" expected="$2" glob="$3" n
220+
# shellcheck disable=SC2086 -- intentional glob expansion
221+
n=$(ls -1 dist/$glob 2>/dev/null | wc -l | tr -d ' ')
222+
if [ "$n" -ne "$expected" ]; then
223+
echo "::error::${label}: expected ${expected}, found ${n} (dist/${glob})"
224+
fail=1
225+
else
226+
echo "ok: ${label} (${n}/${expected})"
227+
fi
228+
}
229+
check "Linux AppImage (x86_64 + aarch64)" 2 'aMule-*-Linux-*.AppImage'
230+
check "Linux Flatpak (x86_64 + aarch64)" 2 'aMule-*-Linux-*.flatpak'
231+
check "macOS Universal2 .dmg" 1 'aMule-*-macOS-universal2.dmg'
232+
check "Windows portable .zip (x64 + arm64)" 2 'aMule-*-Windows-*.zip'
233+
check "Windows installer .exe (x64 + arm64)" 2 'aMule-*-Windows-Setup-*.exe'
234+
check "Source bundle" 1 'aMule-*-src.tar.gz'
235+
if [ "$fail" -ne 0 ]; then
236+
echo "::error::Artifact manifest incomplete — refusing to assemble the draft Release."
237+
exit 1
238+
fi
239+
echo "All 10 expected release artifacts present."
240+
159241
- name: Create draft Release
160242
env:
161243
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
162244
run: |
163245
set -euo pipefail
164246
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
165-
TAG="${{ inputs.tag }}"
247+
TAG="${{ inputs.version }}"
166248
else
167249
TAG="${{ github.ref_name }}"
168250
fi

docs/man/po/manpages-lv.po

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: PACKAGE VERSION\n"
99
"POT-Creation-Date: 2026-06-10 16:45+0200\n"
10-
"PO-Revision-Date: 2026-06-20 02:01+0000\n"
10+
"PO-Revision-Date: 2026-06-23 12:03+0000\n"
1111
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
1212
"Language-Team: none\n"
1313
"Language: lv\n"
@@ -529,7 +529,7 @@ msgstr ""
529529
#. type: Plain text
530530
#: amulecmd.1.in:117
531531
msgid "Get bandwidth limits."
532-
msgstr ""
532+
msgstr "Iegūt datu pārraides ierobežojumu iestatījumus."
533533

534534
#. type: Plain text
535535
#: amulecmd.1.in:119
@@ -684,7 +684,7 @@ msgstr ""
684684
#. type: Plain text
685685
#: amulecmd.1.in:200
686686
msgid "Set bandwidth limits."
687-
msgstr ""
687+
msgstr "Iestatīt datu pārraides ierobežojumus."
688688

689689
#. type: Plain text
690690
#: amulecmd.1.in:202
@@ -1024,7 +1024,7 @@ msgstr "UPnP ports."
10241024
#. type: Plain text
10251025
#: amuleweb.1.in:90
10261026
msgid "Enables using gzip compression in HTTP traffic to save bandwidth."
1027-
msgstr ""
1027+
msgstr "Iespējo gzip saspiešanu HTTP trafikam, lai ietaupītu datu pārraides apjomu."
10281028

10291029
#. type: Plain text
10301030
#: amuleweb.1.in:93

docs/man/po/manpages-ta.po

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: PACKAGE VERSION\n"
99
"POT-Creation-Date: 2026-06-10 16:45+0200\n"
10-
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
10+
"PO-Revision-Date: 2026-06-22 11:01+0000\n"
1111
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
1212
"Language-Team: none\n"
1313
"Language: ta\n"
@@ -69,12 +69,12 @@ msgstr ""
6969
#. type: Plain text
7070
#: amule.1.in:10 amulegui.1.in:10
7171
msgid "[B<-c> I<E<lt>pathE<gt>>] [B<-geometry> I<E<lt>geomE<gt>>]"
72-
msgstr ""
72+
msgstr "[B<-c> I<E<lt>பாதைE<gt>>] [B<-geometry> I<E<lt>வடிவியல்E<gt>>]"
7373

7474
#. type: Plain text
7575
#: amule.1.in:14 amuled.1.in:16
7676
msgid "[B<-w> I<E<lt>pathE<gt>>]"
77-
msgstr ""
77+
msgstr "[B<-w> I<E<lt>பாதைE<gt>>]"
7878

7979
#. type: Plain text
8080
#: amule.1.in:18 amuled.1.in:20

0 commit comments

Comments
 (0)