fix: resolve relative wallpaper paths before creating symlink (#5612)
This commit is contained in:
@@ -9,9 +9,14 @@ if [[ -z $1 ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
BACKGROUND="$1"
|
BACKGROUND="$(realpath "$1")"
|
||||||
CURRENT_BACKGROUND_LINK="$HOME/.config/omarchy/current/background"
|
CURRENT_BACKGROUND_LINK="$HOME/.config/omarchy/current/background"
|
||||||
|
|
||||||
|
if [[ ! -f "$BACKGROUND" ]]; then
|
||||||
|
echo "File does not exist: $BACKGROUND" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# Create symlink to the new background
|
# Create symlink to the new background
|
||||||
ln -nsf "$BACKGROUND" "$CURRENT_BACKGROUND_LINK"
|
ln -nsf "$BACKGROUND" "$CURRENT_BACKGROUND_LINK"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user