First commit
This commit is contained in:
commit
a49c9e47fd
7 changed files with 335 additions and 0 deletions
6
scripts/dotset.sh
Executable file
6
scripts/dotset.sh
Executable file
|
@ -0,0 +1,6 @@
|
|||
mv ~/mdddots ~/.linux
|
||||
|
||||
ln -s ~/.linux/dots/.zshrc ~
|
||||
ln -s ~/.linux/dots/.gitconfig ~
|
||||
ln -s ~/.linux/dots/.XCompose ~
|
||||
ln -s ~/.linux/dots/.conkyrc ~
|
22
scripts/nowplaying.sh
Executable file
22
scripts/nowplaying.sh
Executable file
|
@ -0,0 +1,22 @@
|
|||
#/usr/bin/bash
|
||||
|
||||
ARTIST=$( cmus-remote -Q 2>/dev/null | grep "tag artist" | cut -d " " -f 3- )
|
||||
TITLE=$( cmus-remote -Q 2>/dev/null | grep "tag title" | cut -d " " -f 3- )
|
||||
SPOTIFY_PID="$(pidof -s spotify || pidof -s .spotify-wrapped)"
|
||||
|
||||
if [ -z "$ARTIST" ];
|
||||
then
|
||||
if [ -z "$SPOTIFY_PID" ];
|
||||
then
|
||||
echo "Nothing playing"
|
||||
else
|
||||
if [ -z "$(dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'Metadata'|egrep -A 2 "artist"|egrep -v "artist"|egrep -v "array"|cut -b 27-|cut -d '"' -f 1|egrep -v ^$)" ];
|
||||
then
|
||||
echo "Nothing playing"
|
||||
else
|
||||
echo "$(dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'Metadata'|egrep -A 2 "artist"|egrep -v "artist"|egrep -v "array"|cut -b 27-|cut -d '"' -f 1|egrep -v ^$): $(dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'Metadata'|egrep -A 1 "title"|egrep -v "title"|cut -b 44-|cut -d '"' -f 1|egrep -v ^$)"
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$ARTIST: $TITLE"
|
||||
fi
|
7
scripts/spotify.sh
Executable file
7
scripts/spotify.sh
Executable file
|
@ -0,0 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
title=`dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'Metadata'|egrep -A 1 "title"|egrep -v "title"|cut -b 44-|cut -d '"' -f 1|egrep -v ^$`
|
||||
echo $title
|
||||
|
||||
artist=`dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.freedesktop.DBus.Properties.Get string:'org.mpris.MediaPlayer2.Player' string:'Metadata'|egrep -A 2 "artist"|egrep -v "artist"|egrep -v "array"|cut -b 27-|cut -d '"' -f 1|egrep -v ^$`
|
||||
echo $artist
|
6
scripts/today.sh
Executable file
6
scripts/today.sh
Executable file
|
@ -0,0 +1,6 @@
|
|||
#/usr/bin/bash
|
||||
|
||||
now=$(date "+%Y-%m-%d")
|
||||
tomorrow=$(date "+%Y-%m-%d" -d "+1 day")
|
||||
|
||||
gcalcli agenda $now $tomorrow --military --nodeclined | sed 's/\x1b\[[0-9;]*m//g'
|
Loading…
Add table
Add a link
Reference in a new issue