diff options
author | Tomasz Paweł Gajc <tpg@mandriva.org> | 2009-02-03 15:01:15 +0000 |
---|---|---|
committer | Tomasz Paweł Gajc <tpg@mandriva.org> | 2009-02-03 15:01:15 +0000 |
commit | 54a88f63eb7d4707b72578f91eb44d3fddb9772e (patch) | |
tree | fa89076712ffd7c34a7e263dc7a83276cf1371fb /tools/xfce4-firstrun | |
parent | 7d9dcd1b1a122e9af6fd4bbe9b2508a95c76d7cf (diff) | |
download | config-54a88f63eb7d4707b72578f91eb44d3fddb9772e.tar config-54a88f63eb7d4707b72578f91eb44d3fddb9772e.tar.gz config-54a88f63eb7d4707b72578f91eb44d3fddb9772e.tar.bz2 config-54a88f63eb7d4707b72578f91eb44d3fddb9772e.tar.xz config-54a88f63eb7d4707b72578f91eb44d3fddb9772e.zip |
- rename xfce4-update-config to xfce4-firstrun
- update configs for mdv flavours
Diffstat (limited to 'tools/xfce4-firstrun')
-rw-r--r-- | tools/xfce4-firstrun | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/tools/xfce4-firstrun b/tools/xfce4-firstrun new file mode 100644 index 0000000..200faf9 --- /dev/null +++ b/tools/xfce4-firstrun @@ -0,0 +1,54 @@ +#!/bin/bash + +MDV_FLAVOUR=`echo $META_CLASS` +USER_DESKTOP=`xdg-user-dir DESKTOP` +DESKTOP_FILE=$HOME/.config/autostart/xfce4-firstrun.desktop + +if [ `whoami` = "root" ]; then + echo "Not supported for superuser" + exit || 0 +else + if [ ! -e $DESKTOP_FILE ]; then + echo "Localised desktop folder exists." + if [ ! -d $HOME/.config/autostart ]; then + mkdir -p $HOME/.config/autostart + fi + +cat > $HOME/.config/autostart/xfce4-firstrun.desktop << EOF +[Desktop Entry] +Hidden=true +EOF +# + + if [ $MDV_FLAVOUR = "download" -o $MDV_FLAVOUR = "desktop" ]; then + if [ ! -e $USER_DESKTOP/register.desktop ]; then + cp -f /usr/share/mdk/desktop/free/register.desktop $USER_DESKTOP + fi + + if [ ! -e $USER_DESKTOP/upgrade.desktop ]; then + cp -f /usr/share/mdk/desktop/one/upgrade.desktop $USER_DESKTOP + fi + + if [ ! -e $USER_DESKTOP/mandriva-draklive-install.desktop ]; then + cp -f /usr/share/applications/mandriva-draklive-install.desktop $USER_DESKTOP + fi + + xfdesktop --reload + exit || 0 + + else + if [ ! -e $USER_DESKTOP/register.desktop ]; then + cp -f /usr/share/mdk/desktop/powerpack/register.desktop $USER_DESKTOP + fi + + if [ ! -e $USER_DESKTOP/mandriva-draklive-install.desktop ]; then + cp -f /usr/share/applications/mandriva-draklive-install.desktop $USER_DESKTOP + fi + + xfdesktop --reload + exit || 0 + fi + fi +fi + +#EOF |