diff options
| author | mo khan <mo@mokhan.ca> | 2025-07-02 18:46:21 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2025-07-02 18:46:21 -0600 |
| commit | c1d1fa3b31220dd0aa486ee40cbc304dc6adae95 (patch) | |
| tree | 04894d21a1f6140b0b9d1fc58302dc04fbc6d5b6 | |
| parent | 5a0a1c7a527f78e03900573e7f32edea841a259b (diff) | |
feat: add release infrastructure and installation methods
- Add GitHub Actions workflow for cross-platform binary releases
- Create install.sh script for one-liner installation
- Update README with multiple installation options
- Support Linux, macOS (x86_64 + arm64), and Windows builds
π€ Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
| -rw-r--r-- | .github/workflows/release.yml | 77 | ||||
| -rw-r--r-- | README.md | 37 | ||||
| -rwxr-xr-x | install.sh | 54 |
3 files changed, 157 insertions, 11 deletions
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..dc654a0 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,77 @@ +name: Release + +on: + push: + tags: + - 'v*' + +jobs: + build: + runs-on: ${{ matrix.os }} + strategy: + matrix: + include: + - os: ubuntu-latest + target: x86_64-unknown-linux-gnu + name: ghetto-blaster-linux-x86_64 + - os: macos-latest + target: x86_64-apple-darwin + name: ghetto-blaster-macos-x86_64 + - os: macos-latest + target: aarch64-apple-darwin + name: ghetto-blaster-macos-arm64 + - os: windows-latest + target: x86_64-pc-windows-msvc + name: ghetto-blaster-windows-x86_64 + ext: .exe + + steps: + - uses: actions/checkout@v4 + + - name: Install Rust + uses: dtolnay/rust-toolchain@stable + with: + targets: ${{ matrix.target }} + + - name: Install system dependencies (Linux) + if: matrix.os == 'ubuntu-latest' + run: | + sudo apt-get update + sudo apt-get install -y libasound2-dev pkg-config + + - name: Install system dependencies (macOS) + if: matrix.os == 'macos-latest' + run: | + # macOS has CoreAudio built-in + echo "No additional dependencies needed for macOS" + + - name: Build + run: cargo build --release --target ${{ matrix.target }} + + - name: Package binary (Unix) + if: matrix.os != 'windows-latest' + run: | + cd target/${{ matrix.target }}/release + tar czf ../../../${{ matrix.name }}.tar.gz ghetto-blaster + + - name: Package binary (Windows) + if: matrix.os == 'windows-latest' + run: | + cd target/${{ matrix.target }}/release + 7z a ../../../${{ matrix.name }}.zip ghetto-blaster.exe + + - name: Upload Release Asset (Unix) + if: matrix.os != 'windows-latest' + uses: softprops/action-gh-release@v1 + with: + files: ${{ matrix.name }}.tar.gz + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Upload Release Asset (Windows) + if: matrix.os == 'windows-latest' + uses: softprops/action-gh-release@v1 + with: + files: ${{ matrix.name }}.zip + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
\ No newline at end of file @@ -4,23 +4,38 @@ A terminal-based podcast player with vim-style keybindings, built in Rust with r ## Features -- **TUI Interface**: Clean, terminal-based interface with vim-style navigation -- **Podcast Feeds**: Subscribe to RSS/XML podcast feeds -- **mpv Integration**: High-quality audio playback with on-screen controls -- **Configuration**: YAML-based configuration file -- **Cross-platform**: Works on macOS, Linux, and Windows - -## Prerequisites - -- **Rust**: Install from [rustup.rs](https://rustup.rs/) -- **mpv**: Audio player (`brew install mpv` on macOS, `apt install mpv` on Ubuntu) +- π΅ **Native Rust Audio**: No external dependencies (mpv not required!) +- β‘ **Instant Startup**: Async RSS loading with real-time feed updates +- πΎ **Offline Caching**: Episodes cache to `~/Music/{feed}/` for instant replay +- ποΈ **Winamp-inspired Media Console**: Real-time controls, volume, seek, progress +- π± **Smart Feed Management**: Loading indicators (β³ Loading, β Loaded, β Error) +- πΎπ **Cache Indicators**: See which episodes are cached vs streaming +- β¨οΈ **Vim-style Navigation**: hjkl movement, space for pause, ESC to go back +- π **Background Loading**: TUI appears instantly while feeds load +- π **Real-time UI**: Progress tracking, volume control, playback status +- π₯οΈ **Cross-platform**: Works on macOS, Linux, and Windows + +## Quick Install + +### One-liner (recommended) +```bash +curl -sSL https://raw.githubusercontent.com/xlgmokha/ghetto-blaster/main/install.sh | bash +``` -## Installation +### GitHub Releases +Download pre-built binaries from [Releases](https://github.com/xlgmokha/ghetto-blaster/releases) +### From Source ```bash git clone https://github.com/xlgmokha/ghetto-blaster cd ghetto-blaster cargo build --release +sudo cp target/release/ghetto-blaster /usr/local/bin/ +``` + +### Cargo Install +```bash +cargo install --git https://github.com/xlgmokha/ghetto-blaster ``` ## Usage diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..835a0e2 --- /dev/null +++ b/install.sh @@ -0,0 +1,54 @@ +#!/bin/bash +set -e + +# Ghetto Blaster installer script +REPO="xlgmokha/ghetto-blaster" +BINARY_NAME="ghetto-blaster" + +# Detect OS and architecture +OS=$(uname -s | tr '[:upper:]' '[:lower:]') +ARCH=$(uname -m) + +case $OS in + linux) + case $ARCH in + x86_64) TARGET="linux-x86_64" ;; + *) echo "Unsupported architecture: $ARCH"; exit 1 ;; + esac + ;; + darwin) + case $ARCH in + x86_64) TARGET="macos-x86_64" ;; + arm64) TARGET="macos-arm64" ;; + *) echo "Unsupported architecture: $ARCH"; exit 1 ;; + esac + ;; + *) + echo "Unsupported OS: $OS" + exit 1 + ;; +esac + +echo "π΅ Installing Ghetto Blaster for $OS ($ARCH)..." + +# Get latest release +LATEST_RELEASE=$(curl -s "https://api.github.com/repos/$REPO/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/') +DOWNLOAD_URL="https://github.com/$REPO/releases/download/$LATEST_RELEASE/$BINARY_NAME-$TARGET.tar.gz" + +echo "π¦ Downloading $LATEST_RELEASE..." +curl -L "$DOWNLOAD_URL" -o "/tmp/$BINARY_NAME.tar.gz" + +echo "π Extracting..." +cd /tmp +tar -xzf "$BINARY_NAME.tar.gz" + +echo "π§ Installing to /usr/local/bin..." +sudo mv "$BINARY_NAME" /usr/local/bin/ +sudo chmod +x "/usr/local/bin/$BINARY_NAME" + +echo "β
Installation complete!" +echo "" +echo "π§ Run with: ghetto-blaster" +echo "π Config: ~/.config/ghetto-blaster.yml" +echo "" +echo "π Enjoy your music!"
\ No newline at end of file |
