wok-current annotate aurorials-theme/receipt @ rev 22446
vlc: remove notify deps -> did not help
author | Erkan Yilmaz <erkan@slitaz.org> |
---|---|
date | Mon Dec 23 15:52:17 2019 +0000 (2019-12-23) |
parents | 887b3b11683d |
children | b01314c762e9 |
rev | line source |
---|---|
al@18888 | 1 # SliTaz package receipt. |
al@18888 | 2 |
al@18888 | 3 PACKAGE="aurorials-theme" |
al@18888 | 4 VERSION="20130704" |
al@19126 | 5 CATEGORY="customization" |
al@18888 | 6 SHORT_DESC="Aurorials theme for GTK2, Openbox, SLiM, and wallparer" |
al@18888 | 7 MAINTAINER="al.bobylev@gmail.com" |
al@18888 | 8 LICENSE="GPL3" |
al@18888 | 9 WEB_SITE="http://holkfoor.deviantart.com/art/Aurorials-pack-themes-382752941" |
al@18888 | 10 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
al@18888 | 11 WGET_URL="https://dl.dropboxusercontent.com/s/urt40kxaladwpeu/Aurorials_GTK2_Openbox_Slim_Wallpaper.tar.bz2" |
al@18899 | 12 TAGS="holkfoor openbox slim wallpaper" |
al@19114 | 13 HOST_ARCH="any" |
al@18888 | 14 |
al@18888 | 15 DEPENDS="gtk2-engine-murrine openbox slim" |
al@18899 | 16 BUILD_DEPENDS="wget imagemagick" |
al@18888 | 17 |
al@18888 | 18 # Rules to configure and make the package. |
al@18888 | 19 compile_rules() |
al@18888 | 20 { |
al@18888 | 21 A=Aurorials |
al@18888 | 22 s=$install/usr/share/slim/themes |
al@18888 | 23 t=$install/usr/share/themes |
al@18888 | 24 i=$install/usr/share/images |
al@18888 | 25 mkdir -p $s $t $i |
al@18888 | 26 |
al@18888 | 27 # SLiM theme |
al@18888 | 28 cp -a $src/Slim/$A $s |
al@18888 | 29 ( |
al@18888 | 30 cd $s/$A; |
al@18888 | 31 convert background.png background.jpg; |
al@18888 | 32 rm background.png |
al@18888 | 33 ) |
al@18888 | 34 |
al@18888 | 35 # GTK theme |
al@18888 | 36 cp -a $src/GTK2/$A $t |
al@18888 | 37 # (fix warnings about unsupported options) |
al@18888 | 38 sed -i 's|^.*gradients|#&|' $t/$A/gtk-2.0/gtkrc |
al@18888 | 39 |
al@18888 | 40 # wallpaper |
al@18888 | 41 ln -s ../slim/themes/$A/background.jpg $i/$A.jpg |
al@18888 | 42 } |
al@18888 | 43 |
al@18888 | 44 # Rules to gen a SliTaz package suitable for Tazpkg. |
al@18888 | 45 genpkg_rules() |
al@18888 | 46 { |
al@18888 | 47 cp -a $install/* $fs |
al@18888 | 48 } |
al@18888 | 49 |
al@18888 | 50 post_install() |
al@18888 | 51 { |
al@18888 | 52 # Set GTK+ Theme |
al@18888 | 53 for i in $1/etc/xdg/lxsession/*/desktop.conf \ |
al@18888 | 54 $1/home/*/.config/lxsession/*/desktop.conf; do |
al@18888 | 55 [ -f "$i" ] && sed -i 's|sNet/ThemeName=.*|sNet/ThemeName=Aurorials|' $i |
al@18888 | 56 done |
al@18899 | 57 pgrep lxsession >/dev/null && lxsession -r |
al@18888 | 58 |
al@18888 | 59 # Set Openbox theme |
al@18888 | 60 for i in /etc/xdg/openbox/rc.xml /home/*/.config/openbox/rc.xml; do |
al@18888 | 61 [ -f $i ] && sed -i '/<theme>/,/<name>/ s|>[^<]*<|>Aurorials<|' $i |
al@18888 | 62 done |
al@18899 | 63 pgrep openbox >/dev/null && openbox --reconfigure |
al@18888 | 64 |
al@18888 | 65 # Set SLiM theme |
al@18888 | 66 chroot "$1/" slim-theme -s Aurorials |
al@18888 | 67 |
al@18888 | 68 # Set PCManFM wallpaper |
al@18888 | 69 for i in $1/etc/xdg/pcmanfm/default/pcmanfm.conf \ |
al@18888 | 70 $1/home/*/.config/pcmanfm/*/*.conf; do |
al@18888 | 71 [ -f "$i" ] && sed -i 's|wallpaper[0-9]*=.*|wallpaper=/usr/share/images/Aurorials.jpg|' $i |
al@18888 | 72 done |
al@18888 | 73 if [ -z "$1" -a -n "$(pgrep pcmanfm)" ]; then |
al@18888 | 74 # Change wallpaper for current PCManFM session right now |
al@18888 | 75 su -c 'pcmanfm -w /usr/share/images/Aurorials.jpg' \ |
al@18888 | 76 $(ps aux | grep '[p]cmanfm' | awk 'END{print $2}') |
al@18888 | 77 fi |
al@18888 | 78 } |
al@18888 | 79 |
al@18888 | 80 pre_remove() { |
al@18888 | 81 # Restore GTK+ Theme (Clearlooks Human) |
al@18888 | 82 for i in $1/etc/xdg/lxsession/*/desktop.conf \ |
al@18888 | 83 $1/home/*/.config/lxsession/*/desktop.conf; do |
al@18888 | 84 [ -f "$i" ] && sed -i 's|sNet/ThemeName=.*|sNet/ThemeName=Clearlooks Human|' $i |
al@18888 | 85 done |
al@18899 | 86 pgrep lxsession >/dev/null && lxsession -r |
al@18888 | 87 |
al@18888 | 88 # Restore Openbox theme (SliTaz) |
al@18888 | 89 for i in /etc/xdg/openbox/rc.xml /home/*/.config/openbox/rc.xml; do |
al@18888 | 90 [ -f $i ] && sed -i '/<theme>/,/<name>/ s|>[^<]*<|>SliTaz<|' $i |
al@18888 | 91 done |
al@18899 | 92 pgrep openbox >/dev/null && openbox --reconfigure |
al@18888 | 93 |
al@18888 | 94 # Restore SLiM theme |
al@18888 | 95 chroot "$1/" slim-theme -f Madeirado |
al@18888 | 96 |
al@18888 | 97 # Restore PCManFM wallpaper (slitaz-background.jpg) |
al@18888 | 98 for i in $1/etc/xdg/pcmanfm/default/pcmanfm.conf \ |
al@18888 | 99 $1/home/*/.config/pcmanfm/*/*.conf; do |
al@18888 | 100 [ -f "$i" ] && sed -i 's|wallpaper[0-9]*=.*|wallpaper=/usr/share/images/slitaz-background.jpg|' $i |
al@18888 | 101 done |
al@18888 | 102 if [ -z "$1" -a -n "$(pgrep pcmanfm)" ]; then |
al@18888 | 103 # Change wallpaper for current PCManFM session right now |
al@18888 | 104 su -c 'pcmanfm -w /usr/share/images/slitaz-background.jpg' \ |
al@18888 | 105 $(ps aux | grep '[p]cmanfm' | awk 'END{print $2}') |
al@18888 | 106 fi |
al@18888 | 107 } |