upload
This commit is contained in:
23
bin/pcmanwp
Executable file
23
bin/pcmanwp
Executable file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
# pcmanfm based wallpaper chooser
|
||||
# simple command for now
|
||||
|
||||
CNF_FILE="$HOME/.config/mabox/wallp_dirs.conf"
|
||||
if [ ! -f $CNF_FILE ]; then
|
||||
cat <<EOF > ${CNF_FILE}
|
||||
# User wallpapers directories - one per line
|
||||
# Used by "Choose wallpaper" PCmanFM wrapper
|
||||
# Set wallpapers using context (right click) menu in file manager
|
||||
~/wallpapers/
|
||||
EOF
|
||||
fi
|
||||
#System wallpaper dirs
|
||||
syswpdirs+=("/usr/share/backgrounds")
|
||||
if [ -d "/usr/share/backgrounds/tiled" ]; then
|
||||
syswpdirs+=("/usr/share/backgrounds/tiled")
|
||||
fi
|
||||
|
||||
readarray -t wpdirs < <(grep "^[^#]" "${CNF_FILE}")
|
||||
|
||||
sh -c "pcmanfm -n $(echo ${syswpdirs[@]} ${wpdirs[@]})"
|
||||
Reference in New Issue
Block a user