kaliish-orange-theme/bin/update-default-backgrounds
Raphaël Hertzog 6441885d14
Use kali-wallpapers-2020.4 to store the new wallpapers
Keep the "default" symlink for XFCE in the kali-themes-common package.
We need to embed the version in the package name if we want the old
wallpapers to coexist with the new ones on user's systems to avoid
breaking their non-default backgrounds.
2020-11-02 21:45:30 +01:00

24 lines
989 B
Bash
Executable File

#!/bin/sh
DESTDIR=share/desktop-base/kali-theme/
DESKTOP_BACKGROUND=$1
LOGIN_BACKGROUND=$2
# xfce background
if [ -e wallpapers/backgrounds/kali-16x9/$DESKTOP_BACKGROUND.png ]; then
mv -v wallpapers/backgrounds/kali-16x9/$DESKTOP_BACKGROUND.png \
share/backgrounds/kali-16x9/default
fi
# login/lockscreen
ln -sfv ../../../backgrounds/kali/$LOGIN_BACKGROUND.xml ${DESTDIR}lockscreen/gnome-background.xml
ln -sfv ../../../backgrounds/kali/$LOGIN_BACKGROUND-16x9.png ${DESTDIR}login/background
ln -sfv ../../../backgrounds/kali/$LOGIN_BACKGROUND.svg ${DESTDIR}login/background.svg
# desktop background
kde_wallpaper=$(echo $DESKTOP_BACKGROUND | sed -E 's/(^|-)([a-z])/\U\2/g')
ln -sfv ../../../backgrounds/kali/$DESKTOP_BACKGROUND.xml ${DESTDIR}wallpaper/gnome-background.xml
ln -nsfv ../../../wallpapers/$kde_wallpaper/contents ${DESTDIR}wallpaper/contents
sed -i "s/defaultWallpaperTheme=.*/defaultWallpaperTheme=${kde_wallpaper}/" share/plasma/desktoptheme/kali/metadata.desktop