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

Last change on this file since 2342 was 2342, checked in by hectorgh, 3 years ago

fixing prerms and diversions

File size: 1.5 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
13        ORIGINAL_WHISKER_ES_FILE="/usr/share/locale/es/LC_MESSAGES/xfce4-whiskermenu-plugin.mo"
14        NEW_DIVERTED_ES_FILE="/usr/share/locale/es/LC_MESSAGES/xfce4-whiskermenu-plugin.diverted"
15        LLIUREX_ES_FILE="/usr/share/lliurex-artwork-defaults/whiskermenu/locale/es/xfce4-whiskermenu-plugin.mo"
16
17        ORIGINAL_WHISKER_CA_FILE="/usr/share/locale/ca/LC_MESSAGES/xfce4-whiskermenu-plugin.mo"
18        NEW_DIVERTED_CA_FILE="/usr/share/locale/ca/LC_MESSAGES/xfce4-whiskermenu-plugin.diverted"
19        LLIUREX_CA_FILE="/usr/share/lliurex-artwork-defaults/whiskermenu/locale/ca/xfce4-whiskermenu-plugin.mo"
20
21        if [ -f "$NEW_DIVERTED_ES_FILE" ]; then
22                rm -rf $ORIGINAL_WHISKER_ES_FILE || true
23                dpkg-divert --remove --package ${PKG} --rename --divert "$NEW_DIVERTED_ES_FILE" "$ORIGINAL_WHISKER_ES_FILE"
24
25        fi
26
27        if [ -f "$NEW_DIVERTED_CA_FILE" ]; then
28
29                rm -rf $ORIGINAL_WHISKER_CA_FILE || true 
30                dpkg-divert --remove --package ${PKG} --rename --divert "$NEW_DIVERTED_CA_FILE" "$ORIGINAL_WHISKER_CA_FILE"
31
32        fi
33
34        update-alternatives \
35                --remove  lliurex-default-background.png  /usr/share/backgrounds/lliurex/lliurex16-desktop-HD.png
36
37        update-alternatives --auto lliurex-default-background.png
38
39
40fi
41#DEBHELPER#
42
43exit 0
Note: See TracBrowser for help on using the repository browser.