Adjusted to work with install in PKGBUILD

This commit is contained in:
Maximilian P. Käfer 2021-05-16 19:22:03 +02:00
parent c586c0d420
commit 61f995dbac
Signed by: mpk
GPG Key ID: 035869C949377C5C

View File

@ -2,9 +2,9 @@
# Simple CLI to make wallpaper changes with xwallpaper more comfortable
read -r current_file_path < current_wallpaper.txt
read -r current_file_path < /opt/current_wallpaper.txt
source $(dirname $0)/paperchanger.conf.sh
source /etc/paperchanger.conf.sh
function _help() {
echo ""
@ -29,11 +29,11 @@ function _display() {
function _set() {
current_file_path="$1"
echo "$current_file_path" > current_wallpaper.txt
echo "$current_file_path" > /opt/current_wallpaper.txt
}
function _change_config_path() {
sed -i "s/^default_directory=.*\$/default_directory=${1//\//\\/}/" paperchanger.conf.sh
sed -i "s/^default_directory=.*\$/default_directory=${1//\//\\/}/" /etc/paperchanger.conf.sh
}
case "$#" in