MCPcopy Index your code
hub / github.com/bitc0de/bitify

github.com/bitc0de/bitify @v1.2.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.2.0 ↗ · + Follow
119 symbols 234 edges 25 files 0 documented · 0%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Bitify

Self-hosted YouTube music streaming application built with Next.js.

Preview

Desktop

Desktop

Mobile

Mobile

Playlist

Playlist

Features

  • Stream music from YouTube without downloading files
  • Beautiful dark mode interface
  • Fully responsive design (mobile & desktop)
  • Full playback controls (play, pause, next, previous, shuffle)
  • Volume control with visual feedback
  • Progress bar with seeking and time display
  • Create and manage playlists
  • Global player - music continues playing across page navigation
  • Toast notifications for user feedback
  • Simple JSON file storage - no database setup required
  • Easy Docker deployment
  • Smart search: Search YouTube directly from the app or paste URLs

Recent Updates

v1.2.0 - Latest Improvements

  • YouTube search integration: Search for songs directly in the app without needing URLs
  • Smart input detection: Automatically detects if input is a URL or search query
  • Live search results: Real-time search with thumbnails, duration, and channel info
  • Progress bar fix: Fixed playbar not advancing for single songs

v1.1.0 - Previous Updates

  • Direct song deletion: Removed confirmation dialogs when deleting songs from home page for faster workflow
  • Bulk playlist creation: Add entire playlists directly from YouTube playlist URLs
  • Song tags: Display playlist tags on song cards in the home page for better organization
  • Cross-playlist song movement: Move songs between different playlists with a single click
  • Mobile UI improvements: Song action buttons now appear above the player bar on mobile devices
  • Bulk song selection: Select and delete multiple songs at once from the home page for efficient management

Prerequisites

  • Node.js 20+ (for local development)
  • Docker & Docker Compose (for deployment)
  • Python 3 & yt-dlp (installed automatically in Docker)

Local Development

  1. Install dependencies: bash npm install

  2. Create Python virtual environment: bash python -m venv .venv

  3. Activate the virtual environment:

  4. Linux/macOS: bash source .venv/bin/activate
  5. Windows: bash .venv\Scripts\activate

  6. Install yt-dlp: bash pip install yt-dlp

  7. Run the development server: bash npm run dev

  8. Open your browser: Navigate to http://localhost:3000

The database file (data/db.json) will be created automatically on first run.

Quick Start with Docker (Recommended)

  1. Download the docker-compose.yml file: bash wget https://raw.githubusercontent.com/bitc0de/bitify/main/docker-compose.yml Or on Windows PowerShell: powershell Invoke-WebRequest -Uri https://raw.githubusercontent.com/bitc0de/bitify/main/docker-compose.yml -OutFile docker-compose.yml

  2. Start the application: bash docker-compose up -d

  3. Access the application: Navigate to http://localhost:3000

Your music library will be stored in ./data/db.json and persists across container restarts.

Updating to Latest Version

docker-compose down
docker-compose pull
docker-compose up -d

Complete Cleanup (removes all data)

docker-compose down -v
docker rmi ghcr.io/bitc0de/bitify:latest
rm -rf data/

The Docker image is automatically built and published to GitHub Container Registry on each release.

Build from Source

If you prefer to build the Docker image yourself:

  1. Clone the repository: bash git clone https://github.com/bitc0de/bitify.git cd bitify

  2. Build and run: bash docker build -t bitify . docker-compose up -d

Usage

  1. Add a song: Search for songs by artist/title or paste a YouTube URL in the input field
  2. Search: Type any song name or artist and select from the results dropdown
  3. Play a song: Click the play button on any song card
  4. Control playback: Use the player controls at the bottom of the page
  5. Create playlists: Navigate to Playlists and create your custom collections
  6. Shuffle mode: Toggle shuffle to randomize playback order
  7. Navigate freely: Music continues playing as you browse different pages

Data Storage

All data is stored in a simple JSON file at data/db.json:

{
  "songs": [],
  "playlists": [],
  "playlistSongs": []
}

The file is created automatically on first run. To backup your library, simply copy the data/ folder.

Notes

  • Audio files are never downloaded to the server
  • Streaming URLs are dynamically generated using yt-dlp -g -f bestaudio
  • The application requires yt-dlp and ffmpeg to be installed (included in Docker)
  • All data is stored in a simple JSON file that's created automatically on first run
  • Your music library persists in the ./data folder

License

MIT

Extension points exported contracts — how you extend this code

Toast (Interface)
(no doc)
components/Toast.tsx
Song (Interface)
(no doc)
components/SongCard.tsx
Song (Interface)
(no doc)
components/PlayerBar.tsx
Song (Interface)
(no doc)
components/PlayerContext.tsx
HeaderProps (Interface)
(no doc)
components/Header.tsx
CacheEntry (Interface)
(no doc)
lib/cache.ts
Song (Interface)
(no doc)
lib/db.ts
YtDlpMetadata (Interface)
(no doc)
lib/ytdlp.ts

Core symbols most depended-on inside this repo

showToast
called by 24
components/Toast.tsx
readDb
called by 12
lib/db.ts
writeDb
called by 6
lib/db.ts
executeYtDlp
called by 5
lib/ytdlp.ts
isYoutubeUrl
called by 4
components/Header.tsx
isActive
called by 4
components/Navbar.tsx
playSong
called by 3
components/PlayerContext.tsx
usePlayer
called by 3
components/PlayerContext.tsx

Shape

Function 92
Interface 22
Method 3
Class 2

Languages

TypeScript100%

Modules by API surface

app/page.tsx15 symbols
components/PlayerBar.tsx14 symbols
app/playlists/page.tsx11 symbols
components/SongCard.tsx10 symbols
components/PlayerContext.tsx10 symbols
components/Header.tsx10 symbols
lib/db.ts9 symbols
lib/ytdlp.ts8 symbols
lib/cache.ts6 symbols
components/Toast.tsx6 symbols
components/Navbar.tsx5 symbols
app/api/songs/route.ts2 symbols

For agents

$ claude mcp add bitify \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact