Compare commits
8 Commits
d41c1a0fbc
...
v0.1.4
| Author | SHA1 | Date | |
|---|---|---|---|
| 5eb6afe916 | |||
| 86ddae642f | |||
| 2f7b4f5ced | |||
| b1b33bf3e8 | |||
| 187ce10310 | |||
| 561e192dc2 | |||
| ab833833ea | |||
| 2646c5f084 |
143
.gitea/workflows/release.yml
Normal file
143
.gitea/workflows/release.yml
Normal file
@ -0,0 +1,143 @@
|
|||||||
|
name: Release (AppImage + deb + pacman)
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- 'v*'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-deb-appimage:
|
||||||
|
name: AppImage + deb (Ubuntu)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
env:
|
||||||
|
HW_TOKEN: ${{ secrets.HW_RELEASE_TOKEN }}
|
||||||
|
HW_API: https://git.wlkns.org/api/v1/repos/wlkns-dev/hoerwerk
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: System-Abhängigkeiten
|
||||||
|
run: |
|
||||||
|
sudo apt-get update -q
|
||||||
|
sudo apt-get install -y --no-install-recommends \
|
||||||
|
libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev \
|
||||||
|
librsvg2-dev patchelf file
|
||||||
|
|
||||||
|
- name: Rust-Toolchain
|
||||||
|
run: |
|
||||||
|
cargo -vV 2>/dev/null || {
|
||||||
|
curl -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain stable --profile minimal
|
||||||
|
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
|
||||||
|
}
|
||||||
|
|
||||||
|
- name: Bauen (AppImage + deb)
|
||||||
|
run: |
|
||||||
|
node -v
|
||||||
|
npm install
|
||||||
|
npm run tauri build -- --bundles appimage,deb
|
||||||
|
|
||||||
|
- name: Release anhängen (deb + AppImage)
|
||||||
|
run: |
|
||||||
|
VER="$GITHUB_REF_NAME"
|
||||||
|
set -u
|
||||||
|
|
||||||
|
post_release() {
|
||||||
|
curl -sS -X POST \
|
||||||
|
-H "Authorization: token $HW_TOKEN" \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d "{\"tag_name\":\"$VER\",\"name\":\"Hörwerk $VER\",\"body\":\"Release $VER — AppImage, deb und Arch-Paket.\",\"draft\":false,\"prerelease\":false}" \
|
||||||
|
-w '\n%{http_code}' \
|
||||||
|
-o /tmp/hw-rel-body.json \
|
||||||
|
"$HW_API/releases"
|
||||||
|
}
|
||||||
|
get_release() {
|
||||||
|
curl -sS -H "Authorization: token $HW_TOKEN" \
|
||||||
|
-w '\n%{http_code}' -o /tmp/hw-rel-body.json \
|
||||||
|
"$HW_API/releases/tags/$VER"
|
||||||
|
}
|
||||||
|
|
||||||
|
code=$(post_release | tail -n1)
|
||||||
|
RID=$(grep -o '"id": *[0-9]*' /tmp/hw-rel-body.json | head -n1 | grep -o '[0-9]*')
|
||||||
|
if [ -z "$RID" ] && [ "$code" != "201" ]; then
|
||||||
|
get_release >/dev/null
|
||||||
|
RID=$(grep -o '"id": *[0-9]*' /tmp/hw-rel-body.json | head -n1 | grep -o '[0-9]*')
|
||||||
|
fi
|
||||||
|
if [ -z "$RID" ]; then
|
||||||
|
echo "Release-ID konnte nicht ermittelt werden (code=$code)"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo "Release-ID: $RID"
|
||||||
|
|
||||||
|
for f in src-tauri/target/release/bundle/appimage/*.AppImage src-tauri/target/release/bundle/deb/*.deb; do
|
||||||
|
echo "Lade $(basename "$f") hoch…"
|
||||||
|
c=$(curl -sS -X POST -H "Authorization: token $HW_TOKEN" \
|
||||||
|
-F "attachment=@$f" \
|
||||||
|
-o /tmp/hw-upload.json -w '%{http_code}' \
|
||||||
|
"$HW_API/releases/$RID/assets?name=$(basename "$f")")
|
||||||
|
echo " Upload-Code: $c"
|
||||||
|
case "$c" in 200|201) echo " ok";; *) cat /tmp/hw-upload.json; exit 1;; esac
|
||||||
|
done
|
||||||
|
|
||||||
|
build-pacman:
|
||||||
|
name: pacman (Arch)
|
||||||
|
runs-on: arch-base-devel
|
||||||
|
env:
|
||||||
|
HW_TOKEN: ${{ secrets.HW_RELEASE_TOKEN }}
|
||||||
|
HW_API: https://git.wlkns.org/api/v1/repos/wlkns-dev/hoerwerk
|
||||||
|
steps:
|
||||||
|
- name: Abhängigkeiten (root)
|
||||||
|
run: |
|
||||||
|
pacman -Syu --noconfirm --needed \
|
||||||
|
base-devel git nodejs npm rust python gtk3 webkit2gtk-4.1 \
|
||||||
|
libayatana-appindicator mpv ffmpeg
|
||||||
|
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: pacman-Paket bauen
|
||||||
|
run: |
|
||||||
|
cd packaging/arch
|
||||||
|
sudo useradd -m builder 2>/dev/null || true
|
||||||
|
chown -R builder:builder ..
|
||||||
|
sudo -u builder env HOME=/home/builder makepkg -f --noconfirm
|
||||||
|
|
||||||
|
- name: Release anhängen (pacman)
|
||||||
|
run: |
|
||||||
|
VER="$GITHUB_REF_NAME"
|
||||||
|
set -u
|
||||||
|
|
||||||
|
post_release() {
|
||||||
|
curl -sS -X POST \
|
||||||
|
-H "Authorization: token $HW_TOKEN" \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d "{\"tag_name\":\"$VER\",\"name\":\"Hörwerk $VER\",\"body\":\"Release $VER — AppImage, deb und Arch-Paket.\",\"draft\":false,\"prerelease\":false}" \
|
||||||
|
-w '\n%{http_code}' \
|
||||||
|
-o /tmp/hw-rel-body2.json \
|
||||||
|
"$HW_API/releases"
|
||||||
|
}
|
||||||
|
get_release() {
|
||||||
|
curl -sS -H "Authorization: token $HW_TOKEN" \
|
||||||
|
-w '\n%{http_code}' -o /tmp/hw-rel-body2.json \
|
||||||
|
"$HW_API/releases/tags/$VER"
|
||||||
|
}
|
||||||
|
|
||||||
|
code=$(post_release | tail -n1)
|
||||||
|
RID=$(grep -o '"id": *[0-9]*' /tmp/hw-rel-body2.json | head -n1 | grep -o '[0-9]*')
|
||||||
|
if [ -z "$RID" ] && [ "$code" != "201" ]; then
|
||||||
|
get_release >/dev/null
|
||||||
|
RID=$(grep -o '"id": *[0-9]*' /tmp/hw-rel-body2.json | head -n1 | grep -o '[0-9]*')
|
||||||
|
fi
|
||||||
|
if [ -z "$RID" ]; then
|
||||||
|
echo "Release-ID konnte nicht ermittelt werden (code=$code)"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo "Release-ID: $RID"
|
||||||
|
|
||||||
|
f=$(find "$PWD" -name "hoerwerk-*.pkg.tar.zst" -type f | head -n1)
|
||||||
|
[ -n "$f" ] || { echo "kein pkg.tar.zst gefunden"; exit 1; }
|
||||||
|
echo "Lade $(basename "$f") hoch…"
|
||||||
|
c=$(curl -sS -X POST -H "Authorization: token $HW_TOKEN" \
|
||||||
|
-F "attachment=@$f" \
|
||||||
|
-o /tmp/hw-upload2.json -w '%{http_code}' \
|
||||||
|
"$HW_API/releases/$RID/assets?name=$(basename "$f")")
|
||||||
|
echo "Upload-Code: $c"
|
||||||
|
case "$c" in 200|201) echo ok;; *) cat /tmp/hw-upload2.json; exit 1;; esac
|
||||||
21
LICENSE
Normal file
21
LICENSE
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2026 Stephan Wilkens
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
||||||
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "hoerwerk",
|
"name": "hoerwerk",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "0.1.0",
|
"version": "0.1.4",
|
||||||
"description": "Hörwerk – lokaler Audible-Hörbuch-Player",
|
"description": "Hörwerk – lokaler Audible-Hörbuch-Player",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
31
packaging/arch/PKGBUILD
Normal file
31
packaging/arch/PKGBUILD
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
# Maintainer: Stephan Wilkens
|
||||||
|
pkgname=hoerwerk
|
||||||
|
pkgver=0.1.4
|
||||||
|
pkgrel=1
|
||||||
|
pkgdesc='Lokaler Hörbuch-Player für die eigene Audible-Bibliothek (Tauri 2 + Svelte)'
|
||||||
|
arch=('x86_64')
|
||||||
|
url='https://git.wlkns.org/wlkns-dev/hoerwerk'
|
||||||
|
license=('MIT')
|
||||||
|
depends=('gtk3' 'webkit2gtk-4.1' 'libayatana-appindicator' 'mpv' 'ffmpeg' 'openssl')
|
||||||
|
makedepends=('git' 'nodejs' 'npm' 'rust')
|
||||||
|
source=("git+https://git.wlkns.org/wlkns-dev/hoerwerk.git#tag=v$pkgver")
|
||||||
|
sha256sums=('SKIP')
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cd "$srcdir/hoerwerk"
|
||||||
|
npm install
|
||||||
|
npm run build
|
||||||
|
cd src-tauri
|
||||||
|
cargo build --release
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
cd "$srcdir/hoerwerk"
|
||||||
|
install -Dm755 src-tauri/target/release/hoerwerk "$pkgdir/usr/bin/hoerwerk"
|
||||||
|
install -Dm644 src-tauri/icons/128x128.png "$pkgdir/usr/share/icons/hicolor/128x128/apps/hoerwerk.png"
|
||||||
|
install -Dm644 src-tauri/icons/32x32.png "$pkgdir/usr/share/icons/hicolor/32x32/apps/hoerwerk.png"
|
||||||
|
install -Dm644 src-tauri/icons/icon.png "$pkgdir/usr/share/icons/hicolor/512x512/apps/hoerwerk.png"
|
||||||
|
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/hoerwerk/LICENSE"
|
||||||
|
install -Dm644 packaging/arch/hoerwerk.desktop "$pkgdir/usr/share/applications/hoerwerk.desktop"
|
||||||
|
install -d "$pkgdir/usr/share/hoerwerk"
|
||||||
|
}
|
||||||
10
packaging/arch/hoerwerk.desktop
Normal file
10
packaging/arch/hoerwerk.desktop
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Name=Hörwerk
|
||||||
|
GenericName=Hörbuch-Player
|
||||||
|
Comment=Lokaler Audible-Hörbuch-Player
|
||||||
|
Exec=hoerwerk
|
||||||
|
Icon=hoerwerk
|
||||||
|
Type=Application
|
||||||
|
Categories=AudioVideo;Audio;Player;
|
||||||
|
Keywords=hoerbuch;audible;player;
|
||||||
|
StartupWMClass=hoerwerk
|
||||||
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "hoerwerk"
|
name = "hoerwerk"
|
||||||
version = "0.1.0"
|
version = "0.1.4"
|
||||||
description = "Hörwerk – lokaler Audible-Hörbuch-Player"
|
description = "Hörwerk – lokaler Audible-Hörbuch-Player"
|
||||||
authors = ["Stephan"]
|
authors = ["Stephan"]
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://schema.tauri.app/config/2",
|
"$schema": "https://schema.tauri.app/config/2",
|
||||||
"productName": "hoerwerk",
|
"productName": "hoerwerk",
|
||||||
"version": "0.1.0",
|
"version": "0.1.4",
|
||||||
"identifier": "com.hoerwerk.app",
|
"identifier": "com.hoerwerk.app",
|
||||||
"build": {
|
"build": {
|
||||||
"beforeDevCommand": "npm run dev",
|
"beforeDevCommand": "npm run dev",
|
||||||
@ -27,7 +27,7 @@
|
|||||||
},
|
},
|
||||||
"bundle": {
|
"bundle": {
|
||||||
"active": true,
|
"active": true,
|
||||||
"targets": "all",
|
"targets": ["appimage", "deb"],
|
||||||
"icon": [
|
"icon": [
|
||||||
"icons/32x32.png",
|
"icons/32x32.png",
|
||||||
"icons/128x128.png",
|
"icons/128x128.png",
|
||||||
|
|||||||
@ -893,5 +893,5 @@
|
|||||||
{#if error}
|
{#if error}
|
||||||
<span class="statcell statflex error">{error}</span>
|
<span class="statcell statflex error">{error}</span>
|
||||||
{/if}
|
{/if}
|
||||||
<span class="statcell statend">Hörwerk 0.1.0</span>
|
<span class="statcell statend">Hörwerk 0.1.4</span>
|
||||||
</footer>
|
</footer>
|
||||||
|
|||||||
Reference in New Issue
Block a user