Skip to content

⏯️ MPRIS status and controls module for polybar with text scrolling and icons for app or wesbite.

License

Notifications You must be signed in to change notification settings

0jdxt/polybar-mpris

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

polybar-mpris

This polybar module shows details regarding the currently playing MPRIS item. This script attempts to detect the player or if from the browser, the website, and display an appropriate icon. The top two would be scrolling whereas the last wouldn't.

spotify

youtube

prime

Dependencies

  • playerctl - To interface with Spotify and other MPRIS supporting players
  • zscroll - To scroll the fetched text

Setup

Note: this script can rate limit spotifyd so I have the script update every 10s. To change this or to remove the limit, change or remove the -U 10 option in scroll_status.sh

Be sure to set enable-ipc to true in your bar ane enable the modules like so:

[bar/BAR_NAME]
enable-ipc = true
modules-center = mpris mpris-prev mpris-play-pause mpris-next

Set up the modules in your polybar config. To set which polybar bar has the module, change BAR_NAME to the appropriate name. This module requires a nerd font by default, otherwise change the icons below and in scroll_status.sh to use emoji or font awesome icons.

[module/mpris]
type = custom/script
tail = true
exec = ~/repos/polybar-mpris/scroll_status.sh BAR_NAME

[module/mpris-prev]
type = custom/script
exec = echo ""
click-left = playerctl previous

[module/mpris-play-pause]
type = custom/ipc
hook-0 = echo ""
hook-1 = echo ""
initial = 1
click-left = playerctl play-pause

[module/mpris-next]
type = custom/script
exec = echo ""
click-left = playerctl next

About

⏯️ MPRIS status and controls module for polybar with text scrolling and icons for app or wesbite.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%