Accepting request 75644 from home:vuntz:branches:GNOME:Factory
Update /usr/bin/gnome for GNOME 3 OBS-URL: https://build.opensuse.org/request/show/75644 OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/gnome-session?expand=0&rev=115
This commit is contained in:
parent
1a1ecc3ef4
commit
ce0a8d70a8
91
gnome
91
gnome
@ -1,13 +1,14 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# This is not the original gnome-session but a start script
|
||||
# to install some preconfiguration for GNOME2
|
||||
# to install some preconfiguration for GNOME
|
||||
# and some variables to check.
|
||||
#
|
||||
# For feedback on this script please use
|
||||
# https://bugzilla.novell.com/
|
||||
#
|
||||
|
||||
# Define directory that we use to store migration state
|
||||
if test "x$XDG_CONFIG_HOME" = "x"; then
|
||||
XDG_CONFIG_HOME="$HOME/.config"
|
||||
fi
|
||||
@ -19,67 +20,55 @@ else
|
||||
IS_LIVE_IMAGE="no"
|
||||
fi
|
||||
|
||||
# openSUSE <= 10.3 and SLED <= 10 modified the user GConf database to change background.
|
||||
# New openSUSE obsoletes this mechanism by branding and gnome-wp-list.
|
||||
# We still have to detect old modifications in the user database and remove them.
|
||||
# This code may disappear after SLED 12.
|
||||
#
|
||||
# We also need to fix the case where the user explicitly configured the
|
||||
# background to what used to be the default background; for openSUSE <= 11.3,
|
||||
# the filename was specific to each version of openSUSE.
|
||||
if test "$IS_LIVE_IMAGE" != "yes" -a ! -f "$SUSE_DIR/gnome-11.4-wallpaper-migrated"; then
|
||||
PICTURE_FILENAME=$(gconftool-2 --get --ignore-schema-defaults /desktop/gnome/background/picture_filename 2>/dev/null)
|
||||
PICTURE_OPTIONS=$(gconftool-2 --get --ignore-schema-defaults /desktop/gnome/background/picture_options 2>/dev/null)
|
||||
if test -n "$PICTURE_OPTIONS" -a -n "$PICTURE_FILENAME" -a \
|
||||
"$PICTURE_OPTIONS" != "none" -a \
|
||||
! -e "$PICTURE_FILENAME" -a \( \
|
||||
"$PICTURE_FILENAME" != "${PICTURE_FILENAME#/usr/share/wallpapers/default}" -o \
|
||||
"$PICTURE_FILENAME" = "/usr/share/wallpapers/openSUSE112-1600x1200.png" -o \
|
||||
"$PICTURE_FILENAME" = "/usr/share/backgrounds/daft/daft.xml" -o \
|
||||
"$PICTURE_FILENAME" = "/usr/share/wallpapers/openSUSE113-1600x1200.jpg" -o \
|
||||
"$PICTURE_FILENAME" = "/usr/share/backgrounds/IK/IK.xml" \
|
||||
\); then
|
||||
gconftool-2 --unset /desktop/gnome/background/picture_filename
|
||||
gconftool-2 --unset /desktop/gnome/background/picture_options
|
||||
fi
|
||||
|
||||
mkdir -p -m 0700 "$XDG_CONFIG_HOME"
|
||||
mkdir -p "$SUSE_DIR"
|
||||
touch "$SUSE_DIR/gnome-11.4-wallpaper-migrated"
|
||||
fi
|
||||
# Use gnome-applications.menu instead of applications.menu: its
|
||||
# structure is more appropriate.
|
||||
export XDG_MENU_PREFIX=gnome-
|
||||
|
||||
# Some actions that are specific to the LiveCD
|
||||
if test "$IS_LIVE_IMAGE" = "yes" ; then
|
||||
# Install the live install desktop icon this way until there is a better
|
||||
# solution. The actual files reside in gnome2-SuSE the
|
||||
# /usr/share/applications/YaST2/live-installer.desktop exists on a live
|
||||
# install system
|
||||
if [ -e .config/user-dirs.dirs ]; then
|
||||
. .config/user-dirs.dirs
|
||||
else
|
||||
XDG_DESKTOP_DIR="$HOME/Desktop"
|
||||
fi
|
||||
mkdir -p $XDG_DESKTOP_DIR
|
||||
cp -u /usr/share/applications/YaST2/live-installer.desktop $XDG_DESKTOP_DIR/
|
||||
## Make live installer icon more visible. Note that we can't simply put it on
|
||||
## the desktop, since the desktop is not managed by nautilus anymore (by
|
||||
## default)
|
||||
|
||||
# setup live install to not have a lock-enabled screensaver
|
||||
gconftool-2 --set /apps/gnome-screensaver/lock_enabled --type=bool "false"
|
||||
if test -f /etc/xdg/menus/${XDG_MENU_PREFIX}applications.menu; then
|
||||
# Add live installer to the system tools menu (this is nice to have, and also
|
||||
# required for the favorite app change below)
|
||||
mkdir -p -m 0700 "${XDG_CONFIG_HOME}"
|
||||
mkdir "${XDG_CONFIG_HOME}/menus"
|
||||
cat > "${XDG_CONFIG_HOME}/menus/${XDG_MENU_PREFIX}applications.menu" << EOF
|
||||
<Menu>
|
||||
<Name>Applications</Name>
|
||||
<MergeFile type="parent">/etc/xdg/menus/${XDG_MENU_PREFIX}applications.menu</MergeFile>
|
||||
<Menu>
|
||||
<Name>System</Name>
|
||||
<Include>
|
||||
<Filename>YaST2-live-installer.desktop</Filename>
|
||||
</Include>
|
||||
</Menu>
|
||||
</Menu>
|
||||
EOF
|
||||
|
||||
# setup live install to not start updater-applet
|
||||
if [ -e /usr/share/gnome/autostart/gpk-update-icon.desktop ] ; then
|
||||
mkdir -p ~/.config/autostart
|
||||
cp /usr/share/gnome/autostart/gpk-update-icon.desktop ~/.config/autostart
|
||||
echo "X-GNOME-Autostart-enabled=false" >> ~/.config/autostart/gpk-update-icon.desktop
|
||||
# Add live installer as favorite application to gnome-shell dash
|
||||
FAVORITES=`gsettings get org.gnome.shell favorite-apps`
|
||||
if test $? -eq 0; then
|
||||
FAVORITES=`echo ${FAVORITES} | sed "s:^\[:\['YaST2-live-installer.desktop', :"`
|
||||
gsettings set org.gnome.shell favorite-apps "${FAVORITES}"
|
||||
fi
|
||||
|
||||
# FIXME: we need to add a launcher for gnome-panel (fallback mode)
|
||||
fi
|
||||
|
||||
## Other tweaks
|
||||
|
||||
# setup session to not have a lock-enabled screensaver
|
||||
gsettings set org.gnome.desktop.screensaver lock-enabled false
|
||||
# setup session to not care about updates
|
||||
gsettings set org.gnome.settings-daemon.plugins.updates active false
|
||||
fi
|
||||
|
||||
# Uncomment after SLED12, remove after SLED14:
|
||||
#rm -f ~/.skel/gnome2-run ~/.skel/gnome2-run-9.2 ~/.skel/sled10-run
|
||||
|
||||
# Use gnome-applications.menu instead of applications.menu: its
|
||||
# structure is more appropriate.
|
||||
export XDG_MENU_PREFIX=gnome-
|
||||
|
||||
# TODO: look for a better fix for 11.1
|
||||
export SDL_AUDIODRIVER=pulse
|
||||
if test -f /etc/alsa-pulse.conf ; then
|
||||
|
@ -1,3 +1,23 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jul 7 12:42:34 CEST 2011 - vuntz@opensuse.org
|
||||
|
||||
- Update /usr/bin/gnome script for GNOME 3:
|
||||
+ Remove the migration code for the desktop background: this is
|
||||
based on gconf, and the setting moved to GSettings. Since this
|
||||
setting is not migrated from gconf anyway, the user will get
|
||||
the default background.
|
||||
+ Do not copy live-installer.desktop on the desktop anymore: the
|
||||
desktop is not managed by nautilus by default, so it's useless
|
||||
to put it there. Instead, create a custom applications.menu to
|
||||
add the installer to System Tools, and add the installer as
|
||||
favorite application in gnome-shell. Fix part of bnc#702671.
|
||||
+ Disable the lock setting of the screensaver with GSettings
|
||||
instead of gconf.
|
||||
+ Disable the check for software updates with GSettings, instead
|
||||
of disabling an autostart application (that doesn't exist
|
||||
anymore).
|
||||
+ Generally, this should fix bnc#687778.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Jul 4 18:21:36 CEST 2011 - vuntz@opensuse.org
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user