source: lliurex-artwork-defaults/trunk/fuentes/debian/lliurex-artwork-defaults-desktop.prerm @ 4934

Last change on this file since 4934 was 2746, checked in by daduve, 3 years ago

Add diversion for ubuntu-mate-welcome

File size: 1.8 KB
Line 
1#!/bin/bash
2
3set -e
4
5
6if [ "$1" = "remove" ] ; then
7        PKG="lliurex-artwork-defaults-desktop"
8        ORIGINAL_UNITY_FILE="/usr/share/xsessions/mate.desktop"
9        NEW_DIVERTED_FILE="/usr/share/diverted-sessions/mate.desktop"
10        dpkg-divert --remove --package ${PKG} --rename --divert "$NEW_DIVERTED_FILE" "$ORIGINAL_UNITY_FILE"
11
12        ORIGINAL_UNITY_FILE="/etc/skel/.config/autostart/ubuntu-mate-welcome.desktop"
13        NEW_DIVERTED_FILE="/usr/share/diverted-sessions/ubuntu-mate-welcome.desktop"
14        dpkg-divert --remove --package ${PKG} --rename --divert "$NEW_DIVERTED_FILE" "$ORIGINAL_UNITY_FILE"
15
16        ORIGINAL_WHISKER_ES_FILE="/usr/share/locale/es/LC_MESSAGES/xfce4-whiskermenu-plugin.mo"
17        NEW_DIVERTED_ES_FILE="/usr/share/locale/es/LC_MESSAGES/xfce4-whiskermenu-plugin.diverted"
18        LLIUREX_ES_FILE="/usr/share/lliurex-artwork-defaults/whiskermenu/locale/es/xfce4-whiskermenu-plugin.mo"
19
20        ORIGINAL_WHISKER_CA_FILE="/usr/share/locale/ca/LC_MESSAGES/xfce4-whiskermenu-plugin.mo"
21        NEW_DIVERTED_CA_FILE="/usr/share/locale/ca/LC_MESSAGES/xfce4-whiskermenu-plugin.diverted"
22        LLIUREX_CA_FILE="/usr/share/lliurex-artwork-defaults/whiskermenu/locale/ca/xfce4-whiskermenu-plugin.mo"
23
24        if [ -f "$NEW_DIVERTED_ES_FILE" ]; then
25                rm -rf $ORIGINAL_WHISKER_ES_FILE || true
26                dpkg-divert --remove --package ${PKG} --rename --divert "$NEW_DIVERTED_ES_FILE" "$ORIGINAL_WHISKER_ES_FILE"
27
28        fi
29
30        if [ -f "$NEW_DIVERTED_CA_FILE" ]; then
31
32                rm -rf $ORIGINAL_WHISKER_CA_FILE || true
33                dpkg-divert --remove --package ${PKG} --rename --divert "$NEW_DIVERTED_CA_FILE" "$ORIGINAL_WHISKER_CA_FILE"
34
35        fi
36
37        update-alternatives \
38                --remove  lliurex-default-background.png  /usr/share/backgrounds/lliurex/lliurex16-desktop-HD.png
39
40        update-alternatives --auto lliurex-default-background.png
41
42
43fi
44#DEBHELPER#
45
46exit 0
Note: See TracBrowser for help on using the repository browser.