commit 85588fb9411ff08733234966da148077b7b006b0
parent 4d4d3efe1221640d76d06615a569fb60afc4bb7a
Author: Jacob R. Edwards <jacobouno@protonmail.com>
Date: Sat, 13 Mar 2021 02:51:51 -0800
Revise mpc shell functions
- Remove the unused mt, mc, md, mqp, and ms functions
- Rename mm to mp and mp to mP which is much more intuitive for me
- Add a function, mca, to clear the queue before adding new tracks
- Use egrep(1) to search for songs in mq making it identical to mf
except it searches the queue rather than the database.
Diffstat:
1 file changed, 6 insertions(+), 10 deletions(-)
diff --git a/local/shell/.config/shell/mpc b/local/shell/.config/shell/mpc
@@ -3,22 +3,18 @@
m() mpc "$@"
# player
-mm() m play "$@"
+mP() m prev "$@"
mn() m next "$@"
-mp() m prev "$@"
-mt() m toggle "$@"
+mp() m play "$@"
# queue
ma() m add "$@"
-mc() m clear "$@"
-md() m del "${@:-0}"
-mqp() m searchplay any "$@"
-ms() m shuf "$@"
+mca() { m clear -q && ma "$@"; }
+mq() { m -f %file% playlist | egrep "${@:-.}" ;}
# playlist
ml() m playlist "$@"
# database
-mf() { m listall | egrep "$@" ;}
-mq() m search any "$@"
-mu() m update --wait "$@"
+mf() { m listall | egrep "${@:-.}" ;}
+mu() m update -w "$@"