diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 675d986..ad7e2a9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,8 +19,3 @@ jobs: - run: cargo clippy --all-targets -- -D warnings - run: cargo test - run: cargo build --release - - uses: actions/upload-artifact@v4 - with: - name: mudmouth-${{ matrix.os }} - path: target/release/mudmouth* - if-no-files-found: error diff --git a/README.md b/README.md index 4125e54..bec9df9 100644 --- a/README.md +++ b/README.md @@ -35,9 +35,6 @@ speaker mappings, generated audio, and TTS endpoint stay on your computer. ## Requirements -- Rust stable (edition 2024) -- A terminal with ANSI support: Windows Terminal, iTerm2, Terminal.app, GNOME - Terminal, and similar terminals work well. - A reachable [Kokoro-FastAPI](docs/kokoro-fastapi.json) instance. Install and run it using the upstream [Kokoro-FastAPI instructions](https://github.com/remsky/Kokoro-FastAPI); Mudmouth uses `http://127.0.0.1:8880` by default. diff --git a/docs/development.md b/docs/development.md index 13e3a98..4ddf651 100644 --- a/docs/development.md +++ b/docs/development.md @@ -45,19 +45,14 @@ cargo run --release -- --kokoro-url http://127.0.0.1:8880 ## Release builds -Build Linux and Windows from an x86_64 Linux builder with `release.nix`. Build -macOS on a native x86_64 macOS runner, where Apple's SDK is available. The CI -workflow performs these native builds on every push and retains their binaries -as build artifacts. Package the three binaries with: +Build Linux and Windows binaries locally with `release.nix`, then package them +with: ```bash nix-build release.nix -A linux -o result-linux nix-build release.nix -A windows -o result-windows -# On x86_64 macOS: -nix-build release.nix -A macos -o result-macos ./scripts/package-release.sh \ --linux result-linux/bin/mudmouth \ - --macos result-macos/bin/mudmouth \ --windows result-windows/bin/mudmouth.exe ``` diff --git a/release.nix b/release.nix index 54d68eb..58c3ab2 100644 --- a/release.nix +++ b/release.nix @@ -15,6 +15,5 @@ let }; in { linux = buildMudmouth pkgs; - macos = buildMudmouth pkgs.pkgsCross.x86_64-darwin; windows = buildMudmouth pkgs.pkgsCross.mingwW64; } diff --git a/scripts/package-release.sh b/scripts/package-release.sh index 9f46ae9..3b93e3e 100755 --- a/scripts/package-release.sh +++ b/scripts/package-release.sh @@ -2,27 +2,24 @@ set -euo pipefail usage() { - echo "Usage: $0 --linux PATH --macos PATH --windows PATH" >&2 + echo "Usage: $0 --linux PATH --windows PATH" >&2 exit 2 } linux_binary= -macos_binary= windows_binary= while (($#)); do case "$1" in --linux) linux_binary=${2:-}; shift 2 ;; - --macos) macos_binary=${2:-}; shift 2 ;; --windows) windows_binary=${2:-}; shift 2 ;; *) usage ;; esac done [[ -n "$linux_binary" && -f "$linux_binary" ]] || usage -[[ -n "$macos_binary" && -f "$macos_binary" ]] || usage [[ -n "$windows_binary" && -f "$windows_binary" ]] || usage -version=$(sed -n 's/^version = "\\([^"]*\\)"/\\1/p' Cargo.toml | head -n 1) +version=$(awk -F '"' '$1 ~ /^version = / { print $2; exit }' Cargo.toml) [[ -n "$version" ]] || { echo "Could not read the package version." >&2; exit 1; } dist=dist @@ -43,8 +40,6 @@ package_tarball() { } package_tarball x86_64-unknown-linux-gnu "$linux_binary" -package_tarball x86_64-apple-darwin "$macos_binary" - windows_root="mudmouth-v${version}-x86_64-pc-windows-gnu" mkdir -p "$stage/$windows_root" cp "$windows_binary" "$stage/$windows_root/mudmouth.exe" diff --git a/scripts/publish-release.sh b/scripts/publish-release.sh index c0e3bbd..3a36571 100755 --- a/scripts/publish-release.sh +++ b/scripts/publish-release.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash set -euo pipefail -version=$(sed -n 's/^version = "\\([^"]*\\)"/\\1/p' Cargo.toml | head -n 1) +version=$(awk -F '"' '$1 ~ /^version = / { print $2; exit }' Cargo.toml) tag="v${version}" dist=dist checksums="$dist/SHA256SUMS.txt" @@ -13,8 +13,8 @@ trap 'rm -f "$notes"' EXIT cat > "$notes" <