CI / build (push) Successful in 2m1s
Playback: - Persist the playhead in the playback snapshot and resume from it; restored longform progress is no longer overwritten with 0 on first play. - Previous compares elapsed playtime since the track start, so resuming at 1:00:00 and pressing previous goes back instead of restarting the book. - Auto-advance no longer overwrites completed=true with false, longform PUTs are serialized, and playing rows/search results resume saved positions. - Pause cancels the 400 ms poll; seek errors are reported instead of crashing. Sync and state: - First-sync snapshots keep the first page revision; cached revisions are only trusted for the same server/user. - Refresh re-reads /me, merges local and server longform progress by timestamp, replays newer local positions, and keeps cached longform after deltas. - Logout cancels refresh jobs, suppresses late progress writes, clears after playback teardown, and closes the HTTP client on release. - Failed/racing mood opens clear the previous mood; stale responses cannot replace a newer selection. Mood drafts survive background refreshes. Downloads and storage: - Stream downloads to a .part file and atomically rename on Android/desktop, with a download-specific timeout and no whole-file buffering. - Cache writes are best-effort and atomic; blocked/full web storage no longer leaves the app on the splash screen or blocks playback. - Artwork failures do not fail audio downloads; failed downloads refresh the download index. - Android queues sleep-timer commands before the controller connects. UI: - Music search is wired, debounced and kept separate from mood search. - Player bar respects navigation-bar insets and hides music-only mood actions for longform. Mood gradient handles Int.MIN_VALUE.
63 lines
1.9 KiB
YAML
63 lines
1.9 KiB
YAML
name: CI
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
push:
|
|
branches:
|
|
- main
|
|
tags:
|
|
- "v*"
|
|
pull_request:
|
|
|
|
env:
|
|
# Built by scripts/build-ci-image.sh from ci/Dockerfile.
|
|
CI_IMAGE: gitea.tap-tap.win/taptap/audiomanager-client-ci:3
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: write
|
|
container:
|
|
image: gitea.tap-tap.win/taptap/audiomanager-client-ci:3
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Test and build
|
|
run: |
|
|
set -euo pipefail
|
|
if [[ "$GITHUB_REF" == refs/tags/* ]]; then
|
|
gradle \
|
|
:composeApp:desktopTest \
|
|
:composeApp:assembleDebug \
|
|
:composeApp:packageUberJarForCurrentOS \
|
|
:composeApp:wasmJsBrowserDistribution \
|
|
--console=plain
|
|
else
|
|
# The optimized Wasm build is CPU-bound and slow; main/PR builds
|
|
# only need to prove the web target compiles and bundles.
|
|
gradle \
|
|
:composeApp:desktopTest \
|
|
:composeApp:assembleDebug \
|
|
:composeApp:wasmJsBrowserDevelopmentExecutableDistribution \
|
|
--console=plain
|
|
fi
|
|
|
|
- name: Collect artifacts
|
|
run: |
|
|
set -euo pipefail
|
|
mkdir -p dist
|
|
cp composeApp/build/outputs/apk/debug/composeApp-debug.apk dist/AudioManager.apk
|
|
if [[ "$GITHUB_REF" == refs/tags/* ]]; then
|
|
cp composeApp/build/compose/jars/*.jar dist/AudioManager-desktop.jar
|
|
(cd composeApp/build/dist/wasmJs/productionExecutable && zip -qr "$GITHUB_WORKSPACE/dist/AudioManager-web.zip" .)
|
|
fi
|
|
|
|
- name: Publish release assets
|
|
if: startsWith(github.ref, 'refs/tags/')
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
run: scripts/publish-release.sh dist
|