diff options
| author | Daniel Baumann <daniel@debian.org> | 2010-09-02 23:35:21 +0200 |
|---|---|---|
| committer | Daniel Baumann <daniel@debian.org> | 2011-03-09 17:53:27 +0100 |
| commit | ab8f5db63d44fda0b8b5652aa46c8ac9da4fdd89 (patch) | |
| tree | 423c0a536d1b8821729d5ee6c1d76cba56e5dbad /scripts | |
| parent | 8da0b8e548286fe0093fefa41b0ba25e2a5e803b (diff) | |
| download | live-boot-ab8f5db63d44fda0b8b5652aa46c8ac9da4fdd89.tar.gz live-boot-ab8f5db63d44fda0b8b5652aa46c8ac9da4fdd89.zip | |
Applying patch from Luke Yelavich <themuso@ubuntu.com> to instead of mangling the main sudoers file in accessibility bottom script, create a new file in /etc/sudoers.d and set permissions appropriately.
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/live-bottom/30accessibility | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/scripts/live-bottom/30accessibility b/scripts/live-bottom/30accessibility index ef83c72..4ed1c6d 100755 --- a/scripts/live-bottom/30accessibility +++ b/scripts/live-bottom/30accessibility @@ -66,6 +66,17 @@ remove_applet () chroot /root update-gconf-defaults } +add_sudoers_file () +{ + +cat <<EOF > /root/etc/sudoers.d/a11y-sudo +# TO allow accessibility in GTK to work with sudo. +Defaults env_keep = "ORBIT_SOCKETDIR XDG_SESSION_COOKIE GTK_MODULES" +EOF + + chmod 0440 /root/etc/sudoers.d/a11y-sudo +} + case ${ACCESS} in access=v1) # Lesser Visual Impairment @@ -90,7 +101,7 @@ case ${ACCESS} in gct -s -t string /desktop/gnome/applications/at/visual/exec orca gct -s -t bool /apps/gksu/disable-grab true gct -s -t string /desktop/gnome/applications/window_manager/default /usr/bin/metacity - sed -i -e 's/# Host alias specification/Defaults\tenv_keep = "ORBIT_SOCKETDIR XDG_SESSION_COOKIE GTK_MODULES"\n\n# Host alias specification/g' /root/etc/sudoers + add_sudoers_file if [ -x /root/usr/bin/orca ] then @@ -112,7 +123,7 @@ case ${ACCESS} in gct -s -t string /apps/empathy/conversation/theme classic gct -s -t bool /apps/gksu/disable-grab true gct -s -t string /desktop/gnome/applications/window_manager/default /usr/bin/metacity - sed -i -e 's/# Host alias specification/Defaults\tenv_keep = "ORBIT_SOCKETDIR XDG_SESSION_COOKIE GTK_MODULES"\n\n# Host alias specification/g' /root/etc/sudoers + add_sudoers_file remove_applet fast_user_switch if [ -x /root/usr/bin/orca ] @@ -130,7 +141,7 @@ case ${ACCESS} in gct -s -t bool /apps/gksu/disable-grab true gct -s -t string /desktop/gnome/applications/window_manager/default /usr/bin/metacity gct -s -t string /apps/empathy/conversation/theme classic - sed -i -e 's/# Host alias specification/Defaults\tenv_keep = "ORBIT_SOCKETDIR XDG_SESSION_COOKIE GTK_MODULES"\n\n# Host alias specification/g' /root/etc/sudoers + add_sudoers_file if [ -x /root/usr/bin/orca ] then |
