source: lliurex-up/trunk/old/install-files/usr/bin/lliurex-up-session @ 2636

Last change on this file since 2636 was 2636, checked in by kbut, 5 years ago

add old files

  • Property svn:executable set to *
File size: 1.3 KB
Line 
1#!/bin/bash
2
3
4
5CURRENT_THEME=$(dconf read /org/gnome/desktop/interface/icon-theme)
6
7
8logger -t LliureXUpSession "Checking icon theme"
9
10if [ ${CURRENT_THEME} = "'Humanity'" ]; then
11        logger -t LliureXUpSession "Setting icon theme"
12        dconf write /org/gnome/desktop/interface/icon-theme "'future-green'" || true
13fi
14
15logger -t "LliureXUpSession" "Checking automount"
16rc=0
17lliurex-version |grep -q "server" || rc=1
18
19if [ $rc -eq 0 ]; then
20        Z=$(echo $DISPLAY | cut -d ":" -f 1)
21        if [ ! -z $Z ]; then
22                logger -t "LliureXUpSession" "Disabling automount on ThinClients"
23                dconf write /org/gnome/desktop/media-handling/automount false
24                dconf write /org/gnome/desktop/media-handling/automount-open false
25                dconf write /org/gnome/nautilus/desktop/volumes-visible false 
26        else
27                logger -t "LliureXUpSession" "Enabling on server"
28                dconf write /org/gnome/desktop/media-handling/automount true
29                dconf write /org/gnome/desktop/media-handling/automount-open true
30                dconf write /org/gnome/nautilus/desktop/volumes-visible true 
31        fi
32         
33else
34        logger -t "LliureXUpSession" "Checking automount: Nothing to do"
35        dconf write /org/gnome/desktop/media-handling/automount true
36        dconf write /org/gnome/desktop/media-handling/automount-open true
37        dconf write /org/gnome/nautilus/desktop/volumes-visible true 
38fi
39
40
41exit 0
Note: See TracBrowser for help on using the repository browser.