gpsh(1)

πŸ“¦
this version Β· 2 versions
  • nixos 26.05, nixpkgs unstable, ubuntu resolute, ubuntu stonking (latest)
  • opensuse-leap 16.0
, in nixos 26.05, nixpkgs unstable, ubuntu resolute, ubuntu stonking

πŸ’– gpsh(1) β€” the hxtools girlie's guide to vibing your music library πŸ’–

okay bestie, so this is gpsh, part of hxtools, and it's literally the main character of "find my songs and play them". Let's get into it πŸŽ€


✨ NAME ✨

gpsh β€” select audio files by name and play them πŸ’…


πŸ¦‹ SYNTAX πŸ¦‹

gpsh [-F index.m9u] [-OM,opt] [-blvxz] patterns...

🌸 DESCRIPTION 🌸

so gpsh is a utility that will search the current directory for audio/video files by matching their path and filename with regular expression patterns you drop on the command line, and then it feeds them to a multimedia player. that's the whole vibe. it's giving "grep but make it a DJ" 🎧✨

and it's not just basic β€” gpsh is capable of reading special tracklist files which contain subtrack names and their associated time positions. so like, mixes? handled. no cap. πŸ‘‘

when no pattern is given, all entries are selected. by default, all entries which matched a particular pattern are played back in random order, but order between patterns is retained. so it shuffles inside each pattern, not across them. lowkey smart fr fr 🧚


πŸ’… OPTIONS πŸ’…

  • -F index.m9u β€” give the path to the master index file. and bestie, it's just a dump of the internal array state in Perl form, so M9U is not exactly a format of its own. this index contains: filename, and title and offset (for subtracks inside mixes). iconic minimalism honestly 🌈
  • -OM,mplayer_opt β€” pass an extra argument to mplayer. yes, one extra arg, that's the deal ✨
  • -b β€” do index rebuild in foreground. no waiting in the shadows, we're doing this live πŸ’€
  • -l β€” only grep the database. look, don't touch πŸ™ˆ
  • -v β€” do print the playlist (can be very long). like, genuinely. very long. be warned bestie 😭
  • -x β€” ignore subtracks in a mix, and also avoid reindexing of VBR files. two-for-one βœ‚οΈ
  • -z β€” do not shuffle the play queue / play back in lexicographic order. for the organized girlies πŸŽ€
  • --loop n β€” passes the -loop option to mplayer. ⚠️ note that the option has two dashes for gpsh β€” that's the tea, don't get it twisted β˜•

πŸŽ€ INDEX πŸŽ€

gpsh keeps an index cache, and refreshes it in the background when it is older than a day. very self-care of it honestly 🌸

if there is no index yet, playing files will be delayed until it exists. so like, be patient, it's building the vibe 🫢

directories and files whose name without extension ends in "_noindex" will be skipped. periodt. πŸ’…


🌈 TRACKLISTS FOR MIXES 🌈

gpsh scans all .tls files for the following pattern used to denote a subtrack in a big mix of the same basename:

/^\[(?:(+):)?(+):(+)\](.*)/

Example: audio file: "DJ Doboy - Trancequility volume 01.mp3", tracklist: "DJ Doboy - Trancequility volume 01.tls", TL content: "[48:29] Paul van Dyk - For an angel".

the way that .tls file is literally just holding the timestamps for you... chef's kiss πŸ‘‘βœ¨


gpsh uses a Perl regular expression search across file name (mix name, if any) and subtrack name. so you can just describe the vibe and it finds it πŸ¦‹

Example:

gpsh 'doboy.*trancequility.*paul.van.dyk'

would cause gpsh to search for all PVD tracks in Doboy's Trancequility mixes. and then mplayer will be invoked on "DJ Doboy - Trancequility volume 01.mp3" with automatic seeking to position 48:29, for example. like. it just knows. πŸ”₯


πŸ“ EXTRA OPTIONS πŸ“

gpsh -OM,-af-clr chillout

will invoke mplayer instances with the "-af-clr" option. that's it, that's the trick πŸ’œ


🫢 SEE ALSO 🫢

hxtools(7)


okay that's the whole page bestie, go forth and play your music πŸ’–βœ¨

this one came from hxtools, dated 2015-03-11, and yeah it's gpsh(1) β€” take care of her, she's iconic πŸŽ€πŸŒˆπŸ’…

πŸ“¦ where this page comes from