cupidbity/cupid-music-player
À propos
A pixel-art desktop music player built with Electron, Vite, and React.
Autres projetsWhat you can do
- Pixel-art UI with animated record player, spinning vinyl, and needle
- Record swap animation on song change (pink/blue vinyl alternation)
- Interactive progress bar with draggable star indicator
- Marquee scrolling for long track titles
Progression mesurée des étoiles
- in 24h
- 0
- in 7 days
- -1
- in 15 days
- -1
- in 1 month
- Historique en cours
Variations nettes sur des périodes qui se chevauchent, pas des totaux quotidiens. Les mesures absentes restent vides. Les étoiles indiquent l’intérêt, pas la qualité.
README.md
Originalcupid music player
A pixel-art desktop music player built with Electron, Vite, and React.
Features
- Pixel-art UI with animated record player, spinning vinyl, and needle
- Record swap animation on song change (pink/blue vinyl alternation)
- Interactive progress bar with draggable star indicator
- Marquee scrolling for long track titles
- Pink and blue theme switching with persistent preference
- Spotify integration — browse your playlists and play tracks via yt-dlp
- Apple Music integration — browse your library playlists via MusicKit JS
- YouTube playlists — paste any public playlist URL (no sign-in) or sign in with Google to browse your own
- Local MP3 playback
- Custom frameless window with drag and resize
- Dynamic dock/taskbar icon that matches the active theme
Getting Started
You only need 4 commands. Copy them one at a time:
# 1. Download the code
git clone https://github.com/cupidbity/cupid-music-player.git
# 2. Step INTO the folder you just downloaded (this step is required!)
cd cupid-music-player
# 3. Set up the app (installs deps, downloads the yt-dlp binary, and
# auto-checks/repairs the Electron binary issue some hit on Windows)
npm run setup
# 4. Run the app in dev mode
npm run dev
npm run setup is the recommended one-command setup — it installs dependencies, downloads the yt-dlp binary, and automatically checks for and repairs the Electron binary issue that can otherwise break npm run dev on Windows. If anything was off, just re-run npm run setup. (Plain npm install still works too.)
Hitting an Electron
path.txt/ "failed to install correctly" error, or streaming not working? See TROUBLESHOOTING.md — including the manual Electron binary fix for too-new Node versions.
Prerequisites
Before the commands above will work, you need these installed:
| Tool | Why | Install link |
|---|---|---|
| Node.js 18 or newer | Runs npm and the app's build tools |
nodejs.org — download the LTS version |
| Git | Used by the git clone command above |
git-scm.com — usually pre-installed on macOS/Linux |
To check if you already have them, run:
node --version # should print v18.x.x or higher
npm --version # should print 9.x or higher
git --version # should print git version 2.x.x
If any of those says "command not found," install that tool first.
No Python is needed. The
npm installstep automatically downloads a standaloneyt-dlpbinary for your OS into the project'sbin/folder.
Adding Local Audio Files
The local playlist is driven by a single file, playlist.json, that lives next to your audio files. Drop your songs into the audio folder, list them in the JSON, and the player picks them up.
Where the audio folder lives
- Running from source (dev):
audio/in the project root. - Installed app (macOS):
~/Library/Application Support/Cupid Player/audio/ - Installed app (Windows):
%APPDATA%\Cupid Player\audio\ - Installed app (Linux):
~/.config/Cupid Player/audio/
On first launch, the installed app seeds this folder with the bundled defaults. After that it's yours to edit — the app never overwrites it.
Building your playlist
Drop
.mp3files into the audio folder.Open
playlist.jsonin the same folder and add one entry per song:[ { "file": "my-song.mp3", "title": "My Song", "artist": "Some Artist", "album": "Album Name", "art": "https://example.com/cover.jpg" }, { "file": "another.mp3", "title": "Another Song", "artist": "Someone Else" } ]fileandtitleare required.artist,album, andartare optional.artis a URL to a cover image.- The
filevalue must match the mp3 filename exactly (spaces and case included).
In the app, hit the settings icon and the local tab is selected by default. Reload the app to pick up new edits —
playlist.jsonis read on launch.
Supported formats
.mp3, .m4a, .aac, .flac, .wav, .ogg, .opus.
Spotify Setup
Stream any track from your Spotify playlists. Audio is fetched from YouTube via yt-dlp.
Note: As of February 2026, Spotify requires the developer account that creates the app to have an active Premium subscription (announcement). Without it, the Spotify API returns 403 for all users.
- Create a Spotify app at developer.spotify.com/dashboard
- Add
http://127.0.0.1:5173/callbackas a redirect URI - Copy
.env.exampleto.envand add your Client ID - Add yourself under Settings > User Management
- Click the settings icon in the player > log in
See SPOTIFY_SETUP.md for detailed instructions and troubleshooting.
Apple Music Setup
Browse your Apple Music library playlists. Requires an Apple Developer account. Apple Music subscription is not required for playback.
- Create a MusicKit key at developer.apple.com/account/resources/authkeys
- Download the
.p8key file and place it in the project root - Add
APPLE_TEAM_IDandAPPLE_KEY_IDto your.env - Click the settings icon > switch to apple > log in
See APPLE_MUSIC_SETUP.md for detailed instructions and troubleshooting.
YouTube Setup
Two flows — pick whichever you want by configuring (or not) your .env. No YouTube Premium / no subscription required in either case.
Paste any public playlist URL (zero setup):
- Click the settings icon in the player > switch to youtube
- Paste a YouTube/YouTube Music playlist URL into the box
- Hit
load playlist
Browse your own playlists (requires Google OAuth setup):
- Create a Google Cloud project at console.cloud.google.com, enable YouTube Data API v3
- Configure the OAuth consent screen (External, add yourself as a test user, scope
youtube.readonly) - Create OAuth credentials of type Desktop app
- Add
VITE_YOUTUBE_CLIENT_IDandVITE_YOUTUBE_CLIENT_SECRETto your.env - Click the settings icon > switch to youtube > log in with google
The sign-in option only appears when VITE_YOUTUBE_CLIENT_ID is set; otherwise the URL-paste box shows instead.
See YOUTUBE_SETUP.md for detailed instructions and troubleshooting.
Build
npm run package
Install as Desktop App
macOS:
cp -r "out/mac-arm64/Cupid Player.app" /Applications/
Windows: Run the installer from out/Cupid Player Setup.exe. If npm run package fails at the NSIS step with "Cannot create symbolic link," enable Developer Mode in Settings → System → For developers, then re-run. The unpacked app at out/win-unpacked/Cupid Player.exe is fully runnable in the meantime — no installer required.
Linux: Run the AppImage from out/.
Note: The macOS build is unsigned. On first launch you may need to right-click > Open, or go to System Settings > Privacy & Security to allow it.
Tech Stack
- Electron — desktop app shell (frameless window, IPC, system tray)
- Vite — build tool and dev server
- React — UI framework
- HTML5 Audio — local MP3 playback
- yt-dlp — YouTube audio streaming for Spotify/Apple/YouTube tracks; also fetches public YouTube playlist contents via
--flat-playlist - Spotify Web API — playlist and metadata fetching (OAuth PKCE)
- Apple MusicKit JS — library playlist access (JWT auth)
- YouTube Data API v3 — sign-in browsing of the user's own playlists (Google OAuth PKCE, free quota)
- CSS — custom properties for theming, calc-based responsive scaling
- Node.js — main process (JWT generation, yt-dlp execution)
- jsonwebtoken — Apple Music developer token generation
Explorer des projets similaires
Chargement…