aboutsummaryrefslogtreecommitdiffstats
path: root/.config/init/funcs/mpd-sleep
diff options
context:
space:
mode:
authorkatherine <shmibs@shmibbles.me>2016-10-01 13:58:31 -0700
committerkatherine <shmibs@shmibbles.me>2016-10-01 13:58:31 -0700
commitbacc4127b7da22c61671fe3ce0cef6db103884dd (patch)
treee631d8a0f5609c5137afade0a8b36589997d8346 /.config/init/funcs/mpd-sleep
parent4a879cb286f97f317b1109d8d07be4508c76e5f8 (diff)
downloaddotfiles-bacc4127b7da22c61671fe3ce0cef6db103884dd.tar.gz
overhaul init system
gen files now kept in gen directory. funcs now included in $PATH only if their funcreqs are successfully passed at login, making things cleaner and more system-independent
Diffstat (limited to '.config/init/funcs/mpd-sleep')
-rwxr-xr-x.config/init/funcs/mpd-sleep12
1 files changed, 6 insertions, 6 deletions
diff --git a/.config/init/funcs/mpd-sleep b/.config/init/funcs/mpd-sleep
index c01d734..d821572 100755
--- a/.config/init/funcs/mpd-sleep
+++ b/.config/init/funcs/mpd-sleep
@@ -1,10 +1,10 @@
-#!/bin/zsh
+#!/usr/bin/env zsh
+# power off after mpd stops playing
-# power off after finishing mpd playlist
mpc play > /dev/null
while true; do
- mpc idle player > /dev/null || return 1
- if [[ -z "$(mpc status | grep playing)" ]]; then
- poweroff
- fi
+ mpc idle player > /dev/null || return 1
+ if [[ -z "$(mpc status | grep playing)" ]]; then
+ poweroff
+ fi
done