aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mocplay
diff options
context:
space:
mode:
authorGravatar Arun Prakash Jana <engineerarun@gmail.com>2020-03-16 06:40:02 +0530
committerGravatar Arun Prakash Jana <engineerarun@gmail.com>2020-03-16 07:13:35 +0530
commitb8a973a91ac406266befcb36599ce8df64d096b9 (patch)
tree256fac02bace6a06cad239d37c19d1d400ee40e6 /plugins/mocplay
parenta2c2332fc549b43c91dce97f4c099bfa55762277 (diff)
downloadnnn-b8a973a91ac406266befcb36599ce8df64d096b9.tar.gz
Update plugins to support some env vars
Diffstat (limited to 'plugins/mocplay')
-rwxr-xr-xplugins/mocplay4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/mocplay b/plugins/mocplay
index 30818b2..6f5a2a0 100755
--- a/plugins/mocplay
+++ b/plugins/mocplay
@@ -16,11 +16,11 @@ selection=${XDG_CONFIG_HOME:-$HOME/.config}/nnn/.selection
cmd=$(pgrep -x mocp 2>/dev/null)
ret=$cmd
-SHUFFLE=0
+SHUFFLE="${SHUFFLE:-0}"
mocp_add ()
{
- if [ $SHUFFLE = 1 ]; then
+ if [ "$SHUFFLE" = 1 ]; then
if [ "$resp" = "y" ]; then
arr=$(tr '\0' '\n' < "$selection")
elif [ -n "$1" ]; then