Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
neofetch
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
neofetch
Commits
b7e6c993
Commit
b7e6c993
authored
Nov 25, 2016
by
Dylan Araps
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://github.com/dylanaraps/neofetch
parents
02143b43
1217426b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
1 deletion
+20
-1
CHANGELOG.md
CHANGELOG.md
+2
-0
neofetch
neofetch
+18
-1
No files found.
CHANGELOG.md
View file @
b7e6c993
...
...
@@ -106,8 +106,10 @@
**Song**
<br
\>
-
Added support for Clementine.
**[@konimex](https://github.com/konimex)**
-
Added support for GNOME Music.
**[@konimex](https://github.com/konimex)**
-
Added support for Lollypop.
**[@konimex](https://github.com/konimex)**
-
Added support for Pragha.
**[@konimex](https://github.com/konimex)**
**Public IP**
<br
\>
...
...
neofetch
View file @
b7e6c993
...
...
@@ -1081,7 +1081,7 @@ get_memory() {
get_song
()
{
# This is absurdly long.
player
=
"
$(
ps x |
awk
'!(/awk|Helper|Cache/) && /mpd|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|gnome-music|lollypop/ {printf $5 " " $6; exit}'
)
"
player
=
"
$(
ps x |
awk
'!(/awk|Helper|Cache/) && /mpd|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|gnome-music|lollypop
|clementine|pragha
/ {printf $5 " " $6; exit}'
)
"
case
"
${
player
/*\/
}
"
in
"mpd"
*
)
...
...
@@ -1187,6 +1187,23 @@ get_song() {
song
=
"
${
song
% -
}
"
;;
"clementine"
*
)
# dbus
song
=
"
$(
dbus-send
--print-reply
--dest
=
org.mpris.clementine /org/mpris/MediaPlayer2
\
org.freedesktop.DBus.Properties.Get string:
'org.mpris.MediaPlayer2.Player'
string:
'Metadata'
|
\
awk
-F
'string "'
'/string|array/ {printf "%s",$2; next}{print ""}'
|
\
awk
-F
'"'
'/artist|title/ {printf $2 " - "}'
)
"
song
=
"
${
song
% -
}
"
;;
"pragha"
*
)
artist
=
"
$(
pragha
-c
|
awk
-F
':'
'/artist/ {print $2}'
)
"
title
=
"
$(
pragha
-c
|
awk
-F
':'
'/title/ {print $2}'
)
"
song
=
"
$artist
-
$title
"
;;
*
)
song
=
"Not Playing"
;;
esac
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment