Skip to content

Commit d3061e1

Browse files
committed
Hotfix: Replaces egrep with grep -E (0.5.0)
1 parent fb2377e commit d3061e1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
setup(
66
name="spotibar",
77
description="Spotify plugin for Polybar",
8-
version="0.4.0",
8+
version="0.5.0",
99
url="https://github.com/conor-f/spotibar",
1010
python_requires=">=3.6",
1111
packages=find_packages("src"),

src/spotibar/client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ def is_playing(self):
272272
"""
273273
Returns True if dbus thinks we are currently playing Spotify locally, False otherwise.
274274
"""
275-
cmd = "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'PlaybackStatus'|egrep -A 1 \"string\"|cut -b 26-|cut -d '\"' -f 1|egrep -v ^$"
275+
cmd = "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'PlaybackStatus'| grep -E -A 1 \"string\"|cut -b 26-|cut -d '\"' -f 1| grep -E -v ^$"
276276
try:
277277
if subprocess.check_output(cmd, shell=True, text=True).strip() == "Playing":
278278
self.config.set("last_playing_timestamp", self.get_simple_timestamp())

0 commit comments

Comments
 (0)