dotfiles

My personal shell configs and stuff
git clone git://git.alex.balgavy.eu/dotfiles.git
Log | Files | Refs | Submodules | README | LICENSE

commit f083ff03c1e42886489b873e517452b0a1a204df
parent 91f2f0f0668bc2e0d73cd8149afc461bf0fc80f5
Author: Alex Balgavy <alex@balgavy.eu>
Date:   Tue, 29 Dec 2020 19:18:56 +0100

lf: queue song in mpd

Diffstat:
Mlf/lfrc | 13+++++++++++++
1 file changed, 13 insertions(+), 0 deletions(-)

diff --git a/lf/lfrc b/lf/lfrc @@ -44,6 +44,18 @@ cmd open $opener $fx # define a custom 'rename' command without prompt for overwrite cmd rename %[ -e $1 ] && printf "file exists" || mv $f $1 +# queue an audio file in mpd +cmd queue %{{ + for i in $fx; do + case "$i" in + *.wav|*.flac|*.mp3|*.m4a) + mpc -h ~/.local/share/mpd/socket insert "file://$i" + printf "Queued: %s\n" "$i" + ;; + esac + done +}} + # extract the current file with the right command # (xkcd link: https://xkcd.com/1168/) cmd extract ${{ @@ -245,6 +257,7 @@ map D trash map <enter> open $fx map S shell map Y copy_path +map Q queue map p map pp paste