JukeGram
A full-featured terminal jukebox written in Bash. Search
YouTube,
YouTube Music,
SoundCloud,
Odysee,
Dailymotion,
Rumble, any
PeerTube instance, or a
custom site; stream or download tracks; manage a local library by week; create
multi-format custom playlists (M3U, PLS, XSPF, β¦); build URL-based streaming playlists;
and play music β all from a navigable TUI.
Current version: v3.27 β see
CHANGELOG.md for release notes.
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β βͺ J u k e G r a m βͺ β
β Terminal Jukebox v3.27 β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
MAIN MENU
βΆ [S] Search & Download
[L] Library (by week)
[B] Bookmarks (live streams)
[Z] Shuffle all
[P] Custom playlists
[R] Streaming playlists (URL-based, import / export)
[C] Player controls
[O] Player settings (mpv / no_video / none)
[W] Connect to WiFi (nmtui)
[U] USB / Drive manager
[X] System startup config
[I] Install / check dependencies
[Q] Quit
Features
- Multi-site search β default is YouTube; also YouTube Music, SoundCloud, Odysee (LBRY), Dailymotion, Rumble, PeerTube (any instance host), or a custom yt-dlp prefix / URL template (
{q} = encoded query); history and cache are site-aware
- YouTube search β query yt-dlp, browse 10 results with title, duration, and uploader; live streams are tagged
[LIVE] in the results list; upload date is fetched and stored per result
- Playlist search β from within any search result screen, select "π Search playlists: \<query\>" to switch to a playlist-only search; results list playlist title and channel; each playlist can be downloaded in full (MP3 HQ/STD, Video 320p/720p/1080p) or streamed audio-only
- Full playlist download β download every track in a YouTube playlist to a named subfolder inside the current week's library directory (
YYYY/Week_NN/<playlist-title>/); output is prefixed with the playlist index for correct ordering; the subfolder appears in the Library browser alongside regular week folders
- Upload date display and logging β every stream and download shows the original video's upload date (
YYYY-MM-DD) on screen; a persistent access log (~/.jukegramstreamlog) records each stream/download with timestamp, action type, upload date, title, and URL
- Stream quality selection β stream at 320p (mobile), 480p (default), or 1080p (Full HD)
- Audio-only streaming β stream best available audio with no video window via "βͺ Stream audio only" in any stream action menu
- Stream buffering β mpv pre-buffers network streams to prevent stutter; buffer depth (10 s / 30 s / 60 s / 120 s) is configurable in Player Settings; uses mpv cache with pause-on-underrun so playback resumes smoothly rather than glitching
- Live stream bookmarks β search results identified as live streams show a "β
Bookmark this live stream" option; bookmarks are saved persistently and accessible from
[B] Bookmarks in the main menu; each bookmark can be played at any quality (including audio-only) or removed; press [B] (uppercase) on the now-playing screen to instantly bookmark the current stream without opening any sub-menu
- Quick bookmark from now-playing β
[B] (Shift+B) while a stream is playing immediately saves it to bookmarks; reads the current URL live from mpv IPC; does nothing for local files; [b] lowercase still goes back
- Auto-download + add to last playlist β
[P] on the now-playing screen (and the "β¬+β
" action in search results) downloads the current stream using the configured default format and automatically appends the saved file to the most recently used playlist; if no last playlist is known, a playlist-picker opens immediately after the download so the file is never left unassigned
- Batch download from search results β press
Space on any search result to toggle it selected (β green / β unselected); once one or more items are marked, press D to open a format picker and download all selected tracks in sequence; progress is shown as [N/total] with a β/β per track; selections are cleared after the batch completes; pressing Enter on any result still opens the normal single-item action menu unchanged
- Last-playlist tracking β JukeGram remembers the last playlist you played or added a track to; the
[P] key uses this automatically so no manual selection is needed
- Streaming playlists β URL-based playlists (
[R]) stored as .spl files; hold YouTube links, live stream URLs, or any direct media URL; independent of the local custom playlist system; create, edit, play, shuffle, and delete entries; add tracks directly from the last search results without leaving the playlist editor
- Import / export streaming playlists β export any streaming playlist to a portable
.jkpl file (human-readable, tab-separated); import on another JukeGram instance by pointing to the file path; format is validated by a #JUKEGRAMSPLV1 header before import
- Export to mpv-compatible M3U β export any custom playlist, streaming playlist, or bookmarks list as an
#EXTM3U file compatible with mpv --playlist=<file>; available in the manage menu for all playlist types
- Add / bookmark from now-playing screen β press
[a] while any track is playing to save or queue it: streaming URLs offer "β
Bookmark" or "β Add to streaming playlist"; local files offer "β Add to custom playlist"; reads the current path live from mpv IPC so it works mid-playlist
- Download options β 5 formats: MP3 HQ (~320kbps VBR), MP3 STD (~128kbps), Video 320p/720p/1080p
- Weekly library β tracks organized under
~/Music/JukeGram/YYYY/Week_NN/
- Stay in folder β after playing or acting on a track, the library returns to that week's folder
- Shuffle all β play the entire library in random order
- Custom playlists β create, edit, add/remove tracks, play or shuffle; supports M3U/M3U8, PLS, XSPF, ASX (and JukeGram SPL/JKPL); import external files; open external paths/URLs; entries may be local files or stream URLs; HLS
.m3u8 plays as a single stream
- Media management β delete individual tracks or multi-select bulk delete from the library; delete files from disk directly in the playlist editor
- USB / drive manager β list, mount, unmount drives; browse and play music directly from removable media
- USB media migration β copy or move tracks from removable media into the library; multi-select import with copy/move choice and destination week picker
- Multiple player engines β mpv (default), mplayer, ffplay, vlc
- Video modes β GPU window, audio-only, ASCII art (
--vo=tty), colour ASCII (--vo=caca / libcaca), framebuffer DRM (fb_video)
- Framebuffer video (
fb_video) β renders video via DRM/KMS (--vo=drm) with no X11 required; works on bare TTYs, Raspberry Pi, and headless systems; X11 screen flags are automatically suppressed so mpv does not conflict between X11 and DRM mode
- Visualizers β cava spectrum bars, mpv waveform (
showwaves), mpv vector scope (avectorscope)
- Output device control β select which screen video plays on (multi-monitor, including "All displays" span), and which audio device to use (HDMI, audio jack, PulseAudio/PipeWire)
- TAB / Backspace track skip β during shuffle or playlist playback,
Tab skips to the next track and Backspace returns to the previous; works on macOS and Linux keyboards
- Full transport controls β on the now-playing screen and
[C] Player controls: Space pause/resume, arrow keys seek (Β±10 s / Β±60 s), +/- volume, m mute; live progress bar with time and volume via mpv IPC
- Storage bar in header β live disk-usage bar (used / free / total + colour-coded block bar) shown in the header on every screen
- Network & battery in header β active interface RX/TX byte counters and battery level (with charge state) shown in the header; battery colour-codes green / yellow / red by charge level
- Search result caching β results for the last 5 site+query pairs are cached to disk; re-selecting a history entry is instant (β‘); new searches and explicit refresh re-fetch from the active site (β³)
- yt-dlp upgrade β one-click upgrade in the Install / check dependencies menu; auto-detects pacman (Arch), pipx, or pip3
- Console mode β disables all X11-requiring options; safe on headless systems and TTYs
- System startup config β toggle auto-login on TTY1 and auto-launch JukeGram on boot (console mode only)
- WiFi β launches
nmtui for NetworkManager-based WiFi management
- Dependency installer β checks, installs, and upgrades all packages individually so a single failure does not abort the rest; supports Debian Sid, Ubuntu, and Arch Linux; on Debian/Ubuntu, a failed package install is automatically retried with
apt-get --fix-missing before being counted as a failure
- Uppercase hotkeys β every menu item with a
[X] label can be activated directly by pressing that uppercase letter
- Arrow key navigation throughout;
Esc or q goes back at every screen
- Search history β last 5 queries shown at the top of the search screen; select to re-run instantly, or choose "New search..." to type a fresh query; history is deduplicated and persisted to
~/Music/JukeGram/.jukegram_history
- Kiosk PIN lock β optional PIN that locks the Player Settings menu; set/clear/change from within Settings; main menu shows π when active; wrong PIN returns to main menu
- Kiosk exit protection β when a kiosk PIN is active, pressing
q or Esc at the main menu fires a beep and does nothing; the [Q] Quit item requires the correct PIN before the program exits; prevents unattended kiosks from being closed without the PIN
- Kiosk stream/download restrictions β when a kiosk PIN is active, stream quality and download options can each be locked to a single choice (configured in Player Settings β Kiosk restrictions); the action menu collapses to exactly one stream quality and one download option β no filtering from a long list, just the permitted option
- Colorful TUI β WCAG AA contrast-compliant colour palette, Unicode box-drawing, pixel-accurate border alignment, now-playing bar
- TV safe-area margin β entire TUI is indented by one tab with matching right margin so text survives typical overscan on TVs / HTPCs
Requirements
| Package | Debian / Ubuntu name | Arch Linux name | Role | Required? |
|---|
| mpv | mpv | mpv | Primary player | Yes |
| yt-dlp | via pipx | yt-dlp | Search & download | Yes |
| socat | socat | socat | IPC (track skip, seek, now-playing info, add/bookmark) β python3 is used as fallback | Recommended |
| mplayer | mplayer | mplayer (AUR) | Alternate player | Optional |
| ffmpeg / ffplay | ffmpeg | ffmpeg | MP3 conversion, alternate player | Optional (X11) |
| vlc | vlc | vlc | Alternate player (ncurses) | Optional |
| NetworkManager | network-manager | networkmanager | WiFi management (nmtui) | Optional |
| libcaca | libcaca-utils | libcaca | Colour ASCII video | Optional |
| cava | cava | cava | Spectrum visualizer | Optional |
| pipx | pipx / python3-pipx | python-pipx | Install yt-dlp (Debian only) | Recommended (Debian) |
| udisksctl | udisks2 | udisks2 | No-sudo USB mount/unmount | Optional |
| curl | curl | curl | Odysee / Rumble search helpers | Recommended |
| python3 | python3 | python3 | mpv IPC JSON, Odysee/Rumble/XSPF parsing fallback | Recommended |
Installation
Quick one-liner
Arch Linux β Console mode:
bash
sudo pacman -Sy --noconfirm mpv mplayer vlc networkmanager libcaca cava yt-dlp
Arch Linux β Full mode (includes ffmpeg / ffplay):
bash
sudo pacman -Sy --noconfirm mpv mplayer ffmpeg vlc networkmanager libcaca cava yt-dlp
Debian / Ubuntu β Console mode (no X11, no ffmpeg):
bash
sudo apt-get update && sudo apt-get install -y mpv mplayer vlc network-manager libcaca-utils cava pipx && pipx install yt-dlp && pipx ensurepath
Debian / Ubuntu β Full mode (includes ffmpeg / ffplay):
bash
sudo apt-get update && sudo apt-get install -y mpv mplayer ffmpeg vlc network-manager libcaca-utils cava pipx && pipx install yt-dlp && pipx ensurepath
Built-in installer
JukeGram includes an installer accessible from the main menu (
[I]). It auto-detects the distro (Arch or Debian/Ubuntu), selects the right package names and package manager, and installs each package individually showing a pass/fail result. The displayed one-liner also reflects the detected distro.
The installer menu also offers
β¬ Upgrade yt-dlp β auto-detects the installation method (pacman on Arch, pipx, or pip3) and upgrades yt-dlp in place, showing the version before and after.
Manual script setup
bash
Download or copy jukegram.sh, then:
chmod +x jukegram.sh
./jukegram.sh
If
yt-dlp or
mpv are missing, JukeGram will offer to open the installer automatically on first launch.
If
yt-dlp was installed via
pipx, make sure
~/.local/bin is on your
PATH:
bash
pipx ensurepath
source ~/.bash_profile # or open a new terminal
Usage
Navigation
| Key | Action |
|---|
β / k | Move up |
β / j | Move down |
PgUp / PgDn | Scroll a page |
Home / End | Jump to top / bottom |
Enter | Select |
Space | Toggle selection (multi-select menus and search results) |
q or Esc | Back / cancel |
S, L, Z β¦ | Uppercase hotkey (selects labelled item directly) |
Tab | Skip to next track (shuffle / playlist playback) |
Backspace | Go to previous track (shuffle / playlist playback) |
Space | Pause / resume (now-playing and player controls; mpv) |
β / β | Seek Β±10 s (now-playing and player controls) |
β / β | Seek Β±60 s (now-playing and player controls) |
+ / - | Volume Β±5 (now-playing and player controls) |
m | Mute toggle (now-playing and player controls) |
a | Add to playlist or bookmark (now-playing screen) |
Search & Stream / Download
Select
[S] Search & Download, choose a
search site (default
YouTube), enter a query, and browse results.
| Site | How it searches |
|---|
| YouTube | ytsearch50: via yt-dlp with --flat-playlist (default) |
| YouTube Music | music.youtube.com search (artist / album metadata) |
| SoundCloud | scsearch50: via yt-dlp |
| Odysee | LBRY Lighthouse API β odysee.com claim URLs |
| Dailymotion | Dailymotion site search |
| Rumble | Scrapes rumble.com/search/video β playable video pages (yt-dlp plays each URL) |
| PeerTube⦠| Any PeerTube instance host (e.g. framatube.org, peertube.tv). Uses /api/v1/search/videos; last host remembered. Federated results may live on other instances. |
| Custom⦠| Your yt-dlp prefix (e.g. scsearch50, nicosearch20) or URL template with {q} (encoded) / {query} (raw). Last custom value is remembered. Example for Vimeo-style search: https://vimeo.com/search?q={q} (support depends on yt-dlp / the site). |
History entries remember which site was used (including the PeerTube host); the results header shows the active site. YouTube playlist search remains available only when searching YouTube / YouTube Music.
PeerTube tips
Enter a bare host or full URL: framatube.org or https://tilvids.com
Public instance directory: instances.joinpeertube.org
Requires curl + python3 to call/parse the PeerTube API
Stream and download work on returned watch URLs via yt-dlpβs PeerTube extractor
Multi-select batch download
In the results list, press
Space to toggle any result between unselected
β and selected
β. The header updates with a live count (
β N selected) and the hint bar gains a
[D] Download N selected shortcut. Press
D to open a format picker; all selected tracks are then downloaded in sequence to the current week's library folder. Selections survive navigating into an individual action menu and back. Pressing
Enter on a result item always opens the single-item action menu regardless of what else is selected.
For each individual result:
Stream options (plays immediately via mpv, with automatic stream buffering):
| Option | Quality |
|---|
| Stream 480p | Default β SD/HD balanced |
| Stream 320p | Mobile / low bandwidth |
| Stream 1080p | Full HD |
| Stream audio only | Best available audio, no video window |
Playlist / bookmark options:
| Option | Description |
|---|
| β Add to streaming playlist | Saves the URL and title into a streaming playlist of your choice |
| β
Bookmark this live stream | Live results only β saves URL to ~/Music/JukeGram/.jukegram_bookmarks |
Download options (saves to
~/Music/JukeGram/YYYY/Week_NN/):
| Option | Description |
|---|
| MP3 HQ | Audio only, ~320kbps VBR β best audio quality |
| MP3 STD | Audio only, ~128kbps β smaller file size |
| Video 320p | Mobile-quality video |
| Video 720p | HD video |
| Video 1080p | Full HD video |
Playlist Search & Download
From any search results screen, select
π Search playlists: \<query\> to search YouTube for playlists matching the same keyword. Results show the playlist title and channel name.
For each playlist result:
| Option | Description |
|---|
| β¬ Download all β MP3 HQ | Downloads every track, audio only, ~320kbps VBR |
| β¬ Download all β MP3 STD | Downloads every track, audio only, ~128kbps |
| β¬ Download all β Video 320p/720p/1080p | Downloads every track as MP4 at the chosen resolution |
| βΆ Stream playlist (audio only) | Streams all tracks via mpv without downloading |
Downloaded playlists are saved to
~/Music/JukeGram/YYYY/Week_NN/<playlist-title>/ with filenames prefixed by their playlist index (e.g.
1 - Track Name.mp3).
Now-Playing Screen Controls
| Key | Action |
|---|
Tab | Skip to next track |
Backspace | Go to previous track |
s | Stop playback |
B (uppercase) | Instantly bookmark the current stream (no sub-menu) |
a | Add / bookmark current track (opens context menu) |
P (uppercase or lowercase) | Download current stream and add to last playlist |
b (lowercase) | Back to menu (playback continues) |
β / β | Seek Β±10 s (fbvideo mode only) |
β / β | Seek Β±60 s (fbvideo mode only) |
The upload date of the currently playing stream is shown beneath the track title when available.
#### Quick Bookmark (
[B])
Press
B (Shift+B) to immediately add the current stream URL to your bookmarks β no confirmation screen, no sub-menu. The title is read live from mpv IPC and saved alongside the URL.
[B] only works for network streams (
http://,
https://,
rtmp://); pressing it for a local file does nothing.
#### Add / Bookmark from now-playing (
[a])
Press
a at any time while a track is playing. JukeGram reads the current path from mpv's IPC socket and offers context-appropriate options:
| Currently playing | Options |
|---|
Streaming URL (http://, https://, rtmp://) | β
Bookmark this stream Β· β Add to streaming playlist |
| Local file | β Add to custom playlist |
Requires
socat (or
python3) and the mpv engine. Works mid-playlist β the current track at the moment you press
a is what gets saved.
#### Auto-Download + Add to Last Playlist (
[P])
Press
P while a stream is playing to download it and add the resulting file to the last playlist you interacted with (played or added a track to). The download format follows the
Default download setting in Player Settings.
If a last playlist is known: downloads the track, then appends the file path to that playlist automatically
If no last playlist is known: downloads the track, then immediately opens a playlist picker so the file can be assigned on the spot β nothing is left unassigned
The "last playlist" is updated any time you play a playlist, shuffle a playlist, or add a track to a playlist from any menu
Search History & Caching
The search screen shows the last 5 queries above the text prompt. Each entry is labelled with a speed indicator:
| Indicator | Meaning |
|---|
β‘ | Results cached β selecting this entry is instant |
β³ | No cache yet β yt-dlp will fetch on selection |
Caches are stored in
~/Music/JukeGram/.jukegram_cache/ (one file per query, named by hash). They are pruned automatically when a query falls off the 5-entry history. A
β³ Refresh results (re-fetch from YouTube) option inside the results screen forces a fresh fetch and updates the cache.
Bookmarks
[B] Bookmarks in the main menu shows all saved live stream bookmarks. For each bookmark:
| Option | Description |
|---|
| Stream 480p / 320p / 1080p | Stream at the selected quality |
| Stream audio only | Audio stream, no video window |
| β Remove bookmark | Deletes the entry from the bookmarks file |
| β¬ Export bookmarks as mpv M3U... | Writes an #EXTM3U file loadable with mpv --playlist=<file> |
Bookmarks are stored as tab-separated
url<TAB>title lines in
~/Music/JukeGram/.jukegrambookmarks. The "β
Bookmark" option only appears for results yt-dlp identifies as live (
islive=True); regular videos do not show it in the search results action menu. Streams can also be bookmarked from the now-playing screen with
[a] (context menu) or
[B] (instant, no sub-menu).
#### Exporting Bookmarks as M3U
Select
β¬ Export bookmarks as mpv M3U... to write a standard extended M3U file containing all your bookmarked stream URLs. The default output path is
~/bookmarks.m3u. Play the exported file with:
bash
mpv --playlist=~/bookmarks.m3u
Streaming Playlists
[R] Streaming playlists manages URL-based playlists that can hold any YouTube link, live stream URL, or direct media URL. Unlike custom playlists (which store local file paths), streaming playlists are portable and designed for sharing between machines.
#### Within a streaming playlist you can:
| Action | Description |
|---|
| βΆ Play all | Streams all URLs in order via mpv |
| β³ Shuffle & play | Streams all URLs in random order |
| β Add from last search results | Pick any result from your most recent YouTube search |
| β Add URL manually | Paste a URL and give it a label |
| β Remove tracks | Multi-select tracks to remove |
| β¬ Export to file | Writes a portable .jkpl file |
| β¬ Export as mpv M3U... | Writes a standard #EXTM3U file for use with mpv --playlist= |
| β Delete playlist | Permanently removes the .spl file |
Each track in the list can be played directly at 480p / 320p / 1080p / audio-only, or removed, from its individual action menu.
#### Export
Exporting writes a
.jkpl file (plain text, tab-separated). The default path is
~/jukegram<name>.jkpl. The file begins with a
#JUKEGRAMSPL_V1 header followed by the playlist name, export date, track count, and one
url<TAB>title line per track.
#JUKEGRAMSPLV1
#NAME:My Playlist
#EXPORTED:2026-05-28
#COUNT:3
https://www.youtube.com/watch?v=... Track One
https://www.youtube.com/watch?v=... Track Two
https://www.youtube.com/watch?v=... Track Three
#### Import
From the Streaming Playlists menu, choose
β¬ Import playlist from file.... Enter the path to a
.jkpl file (supports
~ expansion). JukeGram validates the header, previews the first 5 tracks, and prompts for a playlist name before saving. If a playlist with the same name exists, you are asked to confirm before overwriting.
Library
Browse by year and week. Downloaded YouTube playlists appear as named subfolders within their week (e.g.
2026/Week_24/My Playlist/) and are listed alongside regular week entries. Within any folder you can:
Play a single track, queue from a track onwards, or shuffle the week
Add individual tracks to a custom playlist
Delete a single track from the track action menu (with confirmation)
Bulk delete via β Delete tracks... β multi-select with Space, then confirm
After any track action, you return to the same week folder automatically
Custom Playlists
Create named playlists, add tracks from any week folder (multi-select with
Space), reorder by removing and re-adding, and play or shuffle. Custom playlists are stored under
~/Music/JukeGram/custom_playlists/ and support common formats:
| Format | Notes |
|---|
.m3u / .m3u8 | Extended M3U (#EXTINF titles); relative paths resolved; stream URLs allowed |
.pls | Winamp-style FileN / TitleN |
.xspf | XML Shareable Playlist Format |
.asx | Windows Media metafile |
.spl / .jkpl | JukeGram URL+title rows (also under Streaming Playlists) |
HLS .m3u8 | Detected via #EXT-X-* β played as one stream (not expanded) |
From the Custom Playlists menu you can
import an external playlist (converted to extended M3U with resolved paths),
open & play a path or remote playlist URL without importing, or
Play native to hand the file to mpv/mplayer/VLC. Use
Add path or stream URL for radio streams and remote media. Streaming Playlists (
[R]) remain the dedicated URL-centric editor with
.jkpl portable export.
Each track in a playlist offers two removal options:
β Remove from playlist β removes the entry from the .m3u file only
β Delete file from disk β permanently deletes the file and removes it from the playlist
Each playlist's manage menu includes
β¬ Export as mpv M3U... which writes a standard extended M3U with all resolved entries (local paths and stream URLs). Open it with:
bash
mpv --playlist=~/my_playlist.m3u
USB / Drive Manager
Lists all mountable partitions detected by
lsblk. Select a partition to mount or unmount. Uses
udisksctl (no sudo needed) when available, with a
sudo mount fallback.
Once mounted, browse the drive for audio/video files. From the drive's music browser:
| Option | Description |
|---|
| Select a track | Play, copy to library, or move to library |
β Copy all to library | Copies every file on the drive to this week's folder |
β¬ Import selection... | Guided 3-step import flow (see below) |
#### Guided import (
β¬ Import selection...)
Select β multi-select tracks with Space
Action β choose Copy (keep originals on USB) or Move (copy then delete from USB). Move is safe: the source file is only deleted after cp succeeds.
Destination β pick "This week" or choose any existing library week folder
Player Settings
Access via
[O] in the main menu.
| Setting | Options |
|---|
| Console mode | ON / OFF |
| Player engine | mpv (default), mplayer, ffplay, vlc |
| Video / render mode | default, novideo, ttyascii, cacaascii, fbvideo |
| Visualizer | none, cava, mpvwave, mpvscope |
| Normalize audio | ON / OFF β EBU R128 loudnorm via mpv lavfi |
| Default download | mp3hq, mp3std, mp4320p, mp4720p, mp4_1080p |
| Stream quality | 480p (default), 320p, 1080p |
| Stream buffer | 10s, 30s (default), 60s, 120s β seconds of ahead-buffer for network streams |
| Output display | X11: detected active monitors via xrandr + "All displays" option; Console: connected DRM connectors from /sys/class/drm/ |
| Overscan comp. | OFF, 3%, 5%, 8%, 10% β linear --video-scale-x/y (e.g. 5% β scale 0.95) so TV overscan does not crop edges |
| Audio output | auto, detected active sinks (pactl), mpv device list, or manual entry |
| Kiosk PIN | Set / change / clear the kiosk PIN that gates Player Settings |
| Kiosk restrictions | Stream quality limit and download type limit (enforced when a kiosk PIN is active) |
\* Requires X11. Blocked in console mode.
Kiosk Mode
When a
Kiosk PIN is set:
The Player Settings menu requires the PIN to enter
Pressing q or Esc at the main menu fires a terminal beep and does nothing β the program cannot be dismissed without the PIN
Selecting [Q] Quit prompts for the PIN before exiting; wrong PIN cancels and returns to the menu
The
Kiosk restrictions sub-menu (accessible from within Player Settings once unlocked) lets you configure what end-users can do:
Stream quality restriction (kiosk_stream):
| Setting | Behaviour |
|---|
all (default) | All stream qualities available (480p, 320p, 1080p, audio-only) |
480p | Only 480p and audio-only stream offered |
320p | Only 320p and audio-only stream offered |
When a kiosk stream restriction is active, the action menu collapses to exactly one stream quality option rather than filtering a longer list.
Download restriction (kiosk_dl):
| Setting | Behaviour |
|---|
all (default) | All download formats available |
audio | Only MP3 download offered; video download options hidden |
none | No download option shown at all |
Restrictions apply in
showsearchresults (search result action menus) and in
buildstream_menu (used by bookmarks and streaming playlist track actions), so they are consistently enforced everywhere a stream or download is offered.
fb_video uses mpv's
--vo=drm (DRM/KMS) to render video directly to the framebuffer without X11 β useful on bare TTYs and Raspberry Pi.
When
fb_video is active, the now-playing screen gains seek controls via arrow keys:
| Key | Action |
|---|
β | Seek forward 10 seconds |
β | Seek back 10 seconds |
β | Seek forward 60 seconds |
β | Seek back 60 seconds |
Seek requires
socat to communicate with mpv via its IPC socket.
Output Display selection
In
X11 mode, the setting queries
xrandr --listactivemonitors and lists only monitors that are currently active. The selected index is passed as
--screen=N to mpv. An additional
"All displays" option passes
--fs-screen=all --fullscreen to span video across every connected monitor.
In
console mode (or when no display server is detected), the setting scans
/sys/class/drm/card-/status and lists only connectors whose status file reads
connected. The selected connector (e.g.
HDMI-A-1,
DP-1) is passed as
--drm-connector=<name> to mpv when using
fb_video mode. Connectors that are disconnected are not shown.
Overscan Compensation
Some TVs cut off the edges of the picture (overscan). The
Overscan comp. setting shrinks the image with linear mpv
--video-scale-x /
--video-scale-y so the full frame stays inside the TVβs crop.
| Setting | Effect | mpv flags |
|---|
| OFF | No scaling | (none) |
| 3% | Slight zoom-out | --video-scale-x=0.97 --video-scale-y=0.97 |
| 5% | Typical | --video-scale-x=0.95 --video-scale-y=0.95 |
| 8% | Heavy | --video-scale-x=0.92 --video-scale-y=0.92 |
| 10% | Very heavy | --video-scale-x=0.90 --video-scale-y=0.90 |
Applied for single-track play, expanded playlists, and native playlist hand-off (mpv paths). Settings are saved to
~/Music/JukeGram/.jukegram_config.
>
Note: Releases before v3.24 used logβ
--video-zoom=-0.0N, which barely changed the picture. Upgrade and re-select overscan if an older setting still βdoes nothing.β
TUI safe-area margin (text overscan)
Independently of video overscan scaling, the
whole terminal UI is drawn with a
one-tab left indent and a matching reduction in content width (default
8 columns left + right). This keeps menus, the header box, and prompts inside a typical TV safe area when JukeGram runs full-screen on a console or HTPC.
| Constant | Default | Role |
|---|
SAFEINDENT | one tab (\t) | Prefix on every UI line |
SAFEINDENT_COLS | 8 | Columns reserved left and right when computing COLS |
Header Display
The header box shown on every screen contains up to four rows of live system information beneath the title.
Storage Bar
Disk βββββββββββββββββββββββ used 45G / free 89G (33%)
Reads
/ via
df -h. The 22-character block bar (
β /
β) turns yellow at 75% use and red at 90%.
Network & Battery Row
Net β 1G β 204M | π 78% (Charging)
Network β detects the active interface via ip route get 8.8.8.8 (local routing-table lookup, no packet sent), then reads cumulative RX and TX byte counters from /proc/net/dev. Values are formatted as B / K / M / G.
Battery β reads /sys/class/power_supply/BAT*/capacity and /status. Colour-coded: green > 40%, yellow 20β40%, red β€ 20%. The row is omitted when no battery is present (desktop systems).
Download Format Differences
| Format | Description |
|---|
| MP3 HQ | Audio stripped from video, re-encoded to MP3 at VBR quality 0 (~320kbps). Best audio quality, slightly larger file. |
| MP3 STD | Same process but at VBR quality 5 (~128kbps). Good for casual listening, roughly half the file size. |
| Video 320p/720p/1080p | Full video downloaded at the specified maximum height. Merged to MP4 container. |
Output Device Control
#### Video Screen (multi-monitor)
Under
Player Settings β Video screen, JukeGram reads connected monitors via
xrandr --listactivemonitors and lists them by index and connector name (e.g.
0 β HDMI-1,
1 β DP-1). Select the screen index where mpv should open its video window.
auto lets mpv decide (usually the primary display).
"All displays" passes
--fs-screen=all --fullscreen to mpv, spanning the video window across every connected monitor simultaneously.
#### Audio Output Device
Under
Player Settings β Audio output, JukeGram builds a deduplicated device list from two sources and always presents it as an arrow-key menu:
pactl list sinks short (PulseAudio / PipeWire compat) β lists currently active sinks; sinks in RUNNING state are marked with a β active indicator
mpv --audio-device=help β any additional devices mpv knows about that pactl did not already cover
Devices are annotated:
[HDMI] β HDMI audio output
[Analog] β 3.5mm headphone/speaker jack
[PulseAudio] / [PipeWire] β software audio server
[ALSA default] β ALSA system default
β active β sink currently in use
An
"Enter device name manually" option at the bottom allows typing a custom mpv device string (e.g.
alsa/hdmi:CARD=PCH,DEV=0) for devices not auto-detected. Select
auto to use the system default. The selected device is passed to every mpv session via
--audio-device.
Console Mode
Enable console mode when running on a headless server, Raspberry Pi, or bare TTY where no display server is available.
In console mode:
ffplay engine and default video mode are blocked
The installer skips ffmpeg / ffplay
The System startup config option becomes available
Framebuffer video (fb_video) is available β plays video via DRM/KMS (--vo=drm) without X11
System Startup Config
Available under
[X] in the main menu when console mode is on.
Auto-login on TTY1 β writes a systemd getty override so the current user logs in automatically on TTY1 at boot:
/etc/systemd/system/getty@tty1.service.d/autologin.conf
Auto-start JukeGram β appends a guarded block to
~/.bashrc that runs JukeGram on TTY1 login:
bash
>>> JukeGram autostart >>>
if [[ -z "$DISPLAY" && "$(tty)" == "/dev/tty1" ]]; then
exec /path/to/jukegram.sh
fi
<<< JukeGram autostart <<<
Both toggles can be reversed from the same menu.
File Layout
~/Music/JukeGram/
βββ .jukegramconfig # saved settings (searchcustom, search_peertube, overscan, kiosk PIN, β¦)
βββ .jukegram_history # last 5 searches (site-aware tokens, e.g. peertube<TAB>host<TAB>query)
βββ .jukegram_bookmarks # saved stream bookmarks (url<TAB>title, one per line)
βββ .jukegramstreamlog # access log: tab-separated (accessed, action, upload_date, title, url)
βββ .jukegram_cache/ # cached search results (hash of site+query token)
β βββ a1b2c3d4e5f6...
βββ custom_playlists/
β βββ favourites.m3u # custom playlists (m3u/m3u8/pls/xspf/asx/spl/jkpl)
β βββ road_trip.m3u
β βββ imported_radio.pls
β βββ streaming/ # URL-based streaming playlists
β βββ lofi.spl
β βββ live_concerts.spl
βββ 2026/
β βββ Week_20/
β β βββ Track One.mp3
β β βββ Clip.mp4
β β βββ My Playlist/ # downloaded YouTube playlist subfolder
β β βββ 1 - First Track.mp3
β β βββ 2 - Second Track.mp3
β βββ Week_21/
β βββ ...
Stream access log format (.jukegramstreamlog) β tab-separated, one entry per stream or download:
2026-06-08 14:32 stream_480p 2024-11-15 Track Title Here https://youtu.be/...
2026-06-08 14:45 downloadmp3hq 2023-08-22 Another Track https://youtu.be/...
Columns:
accessedtime,
action (e.g.
stream480p,
downloadmp3hq,
streamaudio),
uploaddate (
YYYY-MM-DD or
- if unavailable),
title (truncated to 80 chars),
url.
Streaming playlist file format (.spl):
#JUKEGRAMSPLV1
#NAME:My Playlist
https://www.youtube.com/watch?v=... Track Title
https://www.youtube.com/watch?v=... Another Track
Exported / importable playlist file (.jkpl) β same format with added metadata headers:
#JUKEGRAMSPLV1
#NAME:My Playlist
#EXPORTED:2026-05-28
#COUNT:2
https://www.youtube.com/watch?v=... Track Title
https://www.youtube.com/watch?v=... Another Track
Troubleshooting
Colors not displaying β ensure your terminal supports 256-colour ANSI (
TERM=xterm-256color or similar).
yt-dlp not found after pipx install β run
pipx ensurepath and open a new shell, or add
~/.local/bin to your
PATH manually.
Unable to extract uploader id / YouTube downloads fail β almost always a
too-old system yt-dlp (Debian/Ubuntu apt often ships
2022.04.08). JukeGram auto-picks the newest install it can find (
~/.local/bin / pipx over
/usr/bin) and refuses to start if the only copy is below
2023.03.01. Fix:
bash
pipx install --force yt-dlp && pipx ensurepath
or from the main menu: [I] Install β β¬ Upgrade yt-dlp
Do
not rely on
apt install yt-dlp alone on Debian/Ubuntu β that package is years behind YouTubeβs API.
mpv output corrupts the TUI β this is handled automatically. If you see corruption, switch video mode to
no_video in Player Settings.
USB mount fails without sudo β install
udisksctl (
apt install udisks2) for password-free mounting.
USB move leaves source file behind β the source is only deleted after a successful copy. If
rm fails (e.g. read-only filesystem), the copy is kept and a warning is shown.
Auto-login not taking effect β reboot; the systemd unit change requires a restart of the getty service.
Video plays on wrong screen β go to Player Settings β Video screen and select the correct monitor index.
No audio / wrong audio output β go to Player Settings β Audio output and select the correct device. Run
mpv --audio-device=help in a terminal to see all available device names.
Stream quality too high for connection β go to Player Settings β Stream quality and select 320p.
Stream stutters or buffers frequently β go to Player Settings β Stream buffer and increase the buffer (60 s or 120 s). This pre-fills the cache before playback starts and pauses briefly on underrun instead of glitching.
[B] bookmark does nothing β
[B] only works for network streams (
http://,
https://,
rtmp://). It silently does nothing for local files. If the current mpv IPC path cannot be read (socat/python3 unavailable, or a non-mpv engine is in use), the key is a no-op.
[P] downloads but does not add to a playlist β if no playlist has been played or added to yet in this session,
[P] downloads the track and then immediately opens a playlist-picker so you can assign it on the spot. If the picker is dismissed with
q/Esc, the file is kept in the library but not added to any playlist.
Upload date shows - β the upload date is unavailable for live streams in progress (yt-dlp returns
None for live dates). It is also absent if the yt-dlp network call fails. The download and stream still proceed normally.
[B] bookmark shows "β
Bookmark" option not showing β the option only appears for results yt-dlp identifies as live (
is_live=True). Regular videos and premieres do not qualify. You can still bookmark a stream mid-playback using
[a] on the now-playing screen, or
[B] for an instant bookmark.
Bookmark plays but stream has ended β live streams are time-sensitive. If the stream is offline, mpv will report an error. Remove the stale bookmark and search for the channel again.
Current track not shown during shuffle β the now-playing screen queries mpv via its IPC socket. JukeGram tries
socat first, then falls back to
python3. Install
socat (
apt install socat) for the fastest path; if unavailable, ensure
python3 is installed. The
[a], Tab/Backspace skip, and seek all use the same fallback.
[a] Add/Bookmark shows "Cannot read current track path" β requires
socat or
python3 and the mpv engine. The
[a] key has no effect with mplayer, ffplay, or vlc since those engines do not expose an IPC socket.
Streaming playlist import fails validation β the file's first line must be exactly
#JUKEGRAMSPLV1. Files created by other tools or with a missing header are rejected. Re-export from JukeGram to generate a valid file.
Streaming playlist shows empty after import β entries must be
url<TAB>title (a literal tab character between the URL and title). Lines starting with
# are treated as header comments and skipped.
Framebuffer video (fbvideo) shows blank screen or DRM errors β your user may need to be in the
video group (
sudo usermod -aG video $USER). Also ensure no X server is running on the same TTY. DRM errors now print to the terminal (stderr is no longer suppressed in
fbvideo mode) so the specific error will be visible.
Output display shows "No active DRM connectors" β the display may not be detected until it is connected before boot, or the DRM module may not be loaded. Run
ls /sys/class/drm/ to check.
Overscan compensation does nothing / barely changes the picture β needs
v3.24+ (linear
--video-scale-x/y). On older builds, β5%β used ineffective
--video-zoom=-0.05. Update JukeGram, open Player Settings β Overscan, pick 5% or 8%, and start a new video play (not an already-running process).
Overscan makes the picture too small β try a lower percentage (3% instead of 5% or 8%) or OFF. The optimal value depends on your TV.
Rumble search returns no results β needs network access and
curl (browser-like request to rumble.com). Cloudflare or layout changes can block scraping; try again later or open a Rumble URL via Streaming Playlists / custom URL. Individual Rumble video pages still play via yt-dlp once you have a URL.
Odysee search empty β uses the public Lighthouse API (
curl); check network, or paste an
odysee.com URL into a streaming playlist.
PeerTube search fails / empty β confirm the instance host is reachable (
curl -I https://HOST/api/v1/config). Needs
curl +
python3. Some instances disable search or federation; try another host from
instances.joinpeertube.org.
Tab / Backspace skip not working β requires
socat to communicate with the mpv IPC socket (
apt install socat). Also ensure the player is using the mpv engine (not mplayer/ffplay/vlc).
Battery not shown in header β the system has no battery (desktop), or the kernel power-supply path
/sys/class/power_supply/BAT*/ is absent. This is expected on desktops and in virtual machines.
Network stats show ? or 0 β
ip and
/proc/net/dev are required. If the active interface cannot be detected, the network segment is omitted from the header.
Search cache not speeding up re-queries β cache files live in
~/Music/JukeGram/.jukegram_cache/. If the directory is missing, JukeGram creates it automatically on the next successful search. Check that the music directory is writable.
yt-dlp upgrade reports "not found" β JukeGram checks for
pacman,
pipx, and
pip3 in that order. If none is present, the upgrade cannot proceed β install pipx first (
apt install pipx) and re-try.