From d55ff4ee9424499cf1ab027e57c6a8a2ce15617d Mon Sep 17 00:00:00 2001 From: Michael Straube Date: Tue, 11 Apr 2017 19:03:17 +0200 Subject: [PATCH 1/3] Song: Add support for Deepin Music --- neofetch | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/neofetch b/neofetch index a4d6da0e..758173d7 100755 --- a/neofetch +++ b/neofetch @@ -1284,7 +1284,7 @@ get_memory() { get_song() { # This is absurdly long. - player="$(ps x | awk '!(/awk|Helper|Cache/) && /mpd|mopidy|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|xmms2d|gnome-music|lollypop|clementine|pragha|exaile|juk|bluemindo|guayadeque|yarock|qmmp|quodlibet/ {printf $5 " " $6; exit}')" + player="$(ps x | awk '!(/awk|Helper|Cache/) && /mpd|mopidy|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|xmms2d|gnome-music|lollypop|clementine|pragha|exaile|juk|bluemindo|guayadeque|yarock|qmmp|quodlibet|deepin-music/ {printf $5 " " $6; exit}')" get_song_dbus() { # Multiple players use an almost identical dbus command to get the information. @@ -1312,6 +1312,7 @@ get_song() { "bluemindo"*) get_song_dbus "Bluemindo" ;; "guayadeque"*) get_song_dbus "guayadeque" ;; "yarock"*) get_song_dbus "yarock" ;; + "deepin-music"*) get_song_dbus "deepinmusic" ;; "audacious"*) song="$(audtool current-song)" From b8bcd13346a3c4623c7bd8514892023e1eec5a5a Mon Sep 17 00:00:00 2001 From: Michael Straube Date: Tue, 11 Apr 2017 21:31:26 +0200 Subject: [PATCH 2/3] Song: Add support for Tomahawk --- neofetch | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/neofetch b/neofetch index 758173d7..c3a1e831 100755 --- a/neofetch +++ b/neofetch @@ -1284,7 +1284,7 @@ get_memory() { get_song() { # This is absurdly long. - player="$(ps x | awk '!(/awk|Helper|Cache/) && /mpd|mopidy|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|xmms2d|gnome-music|lollypop|clementine|pragha|exaile|juk|bluemindo|guayadeque|yarock|qmmp|quodlibet|deepin-music/ {printf $5 " " $6; exit}')" + player="$(ps x | awk '!(/ awk|Helper|Cache/) && /mpd|mopidy|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|xmms2d|gnome-music|lollypop|clementine|pragha|exaile|juk|bluemindo|guayadeque|yarock|qmmp|quodlibet|deepin-music|tomahawk/ {printf $5 " " $6; exit}')" get_song_dbus() { # Multiple players use an almost identical dbus command to get the information. @@ -1313,6 +1313,7 @@ get_song() { "guayadeque"*) get_song_dbus "guayadeque" ;; "yarock"*) get_song_dbus "yarock" ;; "deepin-music"*) get_song_dbus "deepinmusic" ;; + "tomahawk"*) get_song_dbus "tomahawk" ;; "audacious"*) song="$(audtool current-song)" From 83a0781a3fe2c64fda98bd9183b5d41a2582f774 Mon Sep 17 00:00:00 2001 From: Michael Straube Date: Wed, 12 Apr 2017 00:16:50 +0200 Subject: [PATCH 3/3] General: Align some lines --- neofetch | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/neofetch b/neofetch index c3a1e831..baef8e4c 100755 --- a/neofetch +++ b/neofetch @@ -1299,21 +1299,21 @@ get_song() { case "${player/*\/}" in "mpd"* | "mopidy"*) song="$(mpc current)" ;; - "mocp"*) song="$(mocp -Q "%artist - %song")" ;; - "google play"*) song="$(gpmdp-remote current)" ;; - "rhythmbox"*) song="$(rhythmbox-client --print-playing)" ;; - "deadbeef"*) song="$(deadbeef --nowplaying-tf '%artist% - %title%')" ;; - "xmms2d"*) song="$(xmms2 current -f '${artist} - ${title}')" ;; - "qmmp"*) song="$(qmmp --nowplaying '%p - %t')" ;; - "gnome-music"*) get_song_dbus "GnomeMusic" ;; - "lollypop"*) get_song_dbus "Lollypop" ;; - "clementine"*) get_song_dbus "clementine" ;; - "juk"*) get_song_dbus "juk" ;; - "bluemindo"*) get_song_dbus "Bluemindo" ;; - "guayadeque"*) get_song_dbus "guayadeque" ;; - "yarock"*) get_song_dbus "yarock" ;; + "mocp"*) song="$(mocp -Q "%artist - %song")" ;; + "google play"*) song="$(gpmdp-remote current)" ;; + "rhythmbox"*) song="$(rhythmbox-client --print-playing)" ;; + "deadbeef"*) song="$(deadbeef --nowplaying-tf '%artist% - %title%')" ;; + "xmms2d"*) song="$(xmms2 current -f '${artist} - ${title}')" ;; + "qmmp"*) song="$(qmmp --nowplaying '%p - %t')" ;; + "gnome-music"*) get_song_dbus "GnomeMusic" ;; + "lollypop"*) get_song_dbus "Lollypop" ;; + "clementine"*) get_song_dbus "clementine" ;; + "juk"*) get_song_dbus "juk" ;; + "bluemindo"*) get_song_dbus "Bluemindo" ;; + "guayadeque"*) get_song_dbus "guayadeque" ;; + "yarock"*) get_song_dbus "yarock" ;; "deepin-music"*) get_song_dbus "deepinmusic" ;; - "tomahawk"*) get_song_dbus "tomahawk" ;; + "tomahawk"*) get_song_dbus "tomahawk" ;; "audacious"*) song="$(audtool current-song)"