diff options
| author | awy <awy@awy.one> | 2025-11-14 23:43:38 +0300 |
|---|---|---|
| committer | awy <awy@awy.one> | 2025-11-14 23:43:38 +0300 |
| commit | c7a88a07b9287db9c129914483f6b3ae1ab5404c (patch) | |
| tree | 73c227c5e8519eb9135f46984e4fc067b316ed1b /.local/bin/rmpcover | |
| download | mangoslice-c7a88a07b9287db9c129914483f6b3ae1ab5404c.tar.gz | |
init
Diffstat (limited to '.local/bin/rmpcover')
| -rwxr-xr-x | .local/bin/rmpcover | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/.local/bin/rmpcover b/.local/bin/rmpcover new file mode 100755 index 0000000..0a312f6 --- /dev/null +++ b/.local/bin/rmpcover @@ -0,0 +1,11 @@ +#!/bin/sh + +ifrunning=$(mpc status | rg -o '\[\w+\] (.*)' | awk '{print $2}') +if [ -z "$ifrunning" ]; then + echo "" +fi + +prefix="/mnt/ssd/music" +albumdir=$(rmpc song | jq -r '.file' | sed 's#/[^/]*$##') +final=$(fd . -e jpg -e png -t f "$prefix/$albumdir/" | head -n 1) +echo "$final" |