diff options
author | Jerry <jvonau@shaw.ca> | 2013-01-29 17:58:33 (GMT) |
---|---|---|
committer | Jerry <jvonau@shaw.ca> | 2013-01-29 17:58:33 (GMT) |
commit | af26c19737eec0c0f9e971b40dff75874e98e272 (patch) | |
tree | f24fbed73ba04ae3c6377fcad3c19cb07d3da280 | |
parent | 400ce66f4b76f4d273b98e4cc735a85acf3f038b (diff) |
clean up dups and remove old configs
-rw-r--r-- | modules/custom_scripts/kspost.91.custom_scripts.inc | 280 |
1 files changed, 9 insertions, 271 deletions
diff --git a/modules/custom_scripts/kspost.91.custom_scripts.inc b/modules/custom_scripts/kspost.91.custom_scripts.inc index 9f38c12..77851f5 100644 --- a/modules/custom_scripts/kspost.91.custom_scripts.inc +++ b/modules/custom_scripts/kspost.91.custom_scripts.inc @@ -6,19 +6,16 @@ mkdir /home/olpc/log #rm /root/mi_lang_pack_v2.sh # add usb_wwlan sd to new inhibit class - modules -touch /etc/powerd/flags/modules-inhibits -echo "usb_wwan" >> /etc/powerd/flags/modules-inhibits +# touch /etc/powerd/flags/modules-inhibits +# echo "usb_wwan" >> /etc/powerd/flags/modules-inhibits # exclude these fedora rpms from ever being updated via yum -mv /etc/yum/olpc-exclude /etc/yum/olpc-exclude.oob -echo "exclude=kernel,xulrunner,firefox" > /etc/yum/olpc-exclude +# mv /etc/yum/olpc-exclude /etc/yum/olpc-exclude.oob +# echo "exclude=kernel,xulrunner,firefox" > /etc/yum/olpc-exclude # keep yum.log around sed -i -e 's+logfile=/var/log/yum.log+logfile=/home/olpc/.sugar/default/yum.log+' /etc/yum.conf -# use NM keyfile in place of ifcfg-rh -sed -i -e 's/ifcfg-rh/keyfile/' /etc/NetworkManager/NetworkManager.conf - # toggle setting the rtc sed -i -e "s/SYNC_HWCLOCK=no/SYNC_HWCLOCK=yes/" /etc/sysconfig/ntpdate @@ -103,16 +100,7 @@ sed -i -e "s/=https/=http/" /etc/yum.repos.d/fedora-updates-testing.repo # extend yum's metadata timeout, won't change now sed -i -e "s/metadata_expire=7d/metadata_expire=never/" /etc/yum.repos.d/fedora.repo -sed -i -e "s/metadata_expire=7d/metadata_expire=never/" /etc/yum.repos.d/fedora-updates.repo - -# enable ctrl_alt_bksp shortcut to kill X server -sed -i -e '/DontZap/d' /usr/share/olpc-utils/xorg.conf.d/xo1.75.conf -sed -i -e '/DontZap/d' /usr/share/olpc-utils/xorg.conf.d/xo1.5.conf -sed -i -e '/DontZap/d' /usr/share/olpc-utils/xorg.conf.d/xo1.conf - -# Disable "requiretty" for "wheel" group, so that "sudo" commands -# are be able to run in a terminal-less environment. -echo "Defaults:%wheel !requiretty" >> /etc/sudoers +# sed -i -e "s/metadata_expire=7d/metadata_expire=never/" /etc/yum.repos.d/fedora-updates.repo # Configure sugar-client for yum based automatic updater cat >> "/etc/sugar-client.conf" << __EOF__ @@ -166,73 +154,6 @@ step = 60 enabled = true __EOF__ -cat << EOF > /usr/bin/yumfix -#!/usr/bin/env python -# Copyright (C) 2011, OLPC-AU. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - -import os -import sys -import string -import gettext -import gconf - -def main(): - - - ## JV export http_proxy from .gconf - yumtmp = open("/tmp/yum.conf.mod", "w") - if not os.path.exists('/home/olpc/.gconf/system/proxy'): - yumtmp.close() - sys.exit(1) - sys_dir = '/system/http_proxy' - client = gconf.client_get_default() - use_proxy = client.get_string('/system/proxy/mode') - if use_proxy != 'none': - http_host = client.get_string('%s/host' % sys_dir) - http_port = client.get_int('%s/port' % sys_dir) - proxy_info = '%s:%d' % (http_host, http_port) - yumtmp.write('proxy=http://%s\n' % proxy_info) - use_auth = client.get_bool('%s/use_authentication' % sys_dir) - if use_auth is True: - auth_user = client.get_string('%s/authentication_user' % sys_dir) - yumtmp.write('proxy_username=%s\n' % auth_user) - auth_pass = client.get_string('%s/authentication_password' % sys_dir) - yumtmp.write('proxy_password=%s\n' % auth_pass) - else: - pass - yumtmp.close() - -main() - -EOF -chmod 755 /usr/bin/yumfix - -# run the above from ~/.xsession -echo "/usr/bin/yumfix" > /home/olpc/.xsession -echo "sugar-client session" >> /home/olpc/.xsession -echo "rm -rf /home/olpc/.audacity-data/tmp/*" >> /home/olpc/.xsession - -# add external file for yum to reference -echo "include=/tmp/yum.conf.mod" >> /etc/yum.conf - -# issue 1588 Need to make soft-links to join library-versions. -ln -s /usr/lib/libssl.so.10 /usr/lib/libssl.so.8 -ln -s /usr/lib/libcrypto.so /usr/lib/libcrypto.so.8 - #### Common Customizations Below #### # Fix audacity in gnome @@ -259,62 +180,6 @@ EOF chown olpc:olpc /home/olpc/.audacity-data/ -R -# Fix Xvnc in gnome -mkdir -m 755 -p /home/olpc/.local/share/applications - -cat << EOF > /home/olpc/.local/share/applications/x11vnc.desktop -#!/usr/bin/env xdg-open -[Desktop Entry] -Name=X11VNC Server -Name[es]=Servidor VNC -Comment=Share this desktop by VNC -Comment[es]=Compartir este escritorio con VNC -Exec=x11vnc -loop -o /tmp/x11vnc.log -Icon=computer -Terminal=false -Type=Application -StartupNotify=false -#StartupWMClass=x11vnc_port_prompt -Categories=Network;RemoteAccess; -EOF - -chown olpc:olpc /home/olpc/.local/share/applications/x11vnc.desktop - -# Fix Etoys in gnome -cat << EOF > /usr/share/pixmaps/etoys.svg -<?xml version="1.0" ?><!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd' [ - <!ENTITY stroke_color "#010101"> - <!ENTITY fill_color "#FFFFFF"> -]><svg enable-background="new 0 0 55 55" height="55px" version="1.1" viewBox="0 0 55 55" width="55px" x="0px" xml:space="preserve" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" y="0px"><g display="block" id="activity-etoys"> - <g display="inline"> - <path d=" M38.395,40.393c-0.614,0.214-9.218-9.666-9.849-9.828c-0.632-0.163-13.004,3.906-13.416,3.423 c-0.412-0.484,6.202-11.419,6.177-12.038c-0.024-0.619-8.007-10.704-7.643-11.22c0.363-0.517,13.466,2.533,14.08,2.317 c0.613-0.216,8.677-10.799,9.305-10.634c0.627,0.165,1.631,12.98,2.036,13.472c0.402,0.49,12.795,4.16,12.813,4.783 c0.021,0.621-12.244,5.76-12.601,6.282C38.941,27.473,39.009,40.179,38.395,40.393z" fill="&fill_color;" id="path4637" stroke="&stroke_color;" stroke-linecap="round" stroke-linejoin="bevel" stroke-width="3.5"/> - <path d="M12.729,38.05L3.156,52.411l0,0" fill="none" id="path5528" stroke="&stroke_color;" stroke-linecap="round" stroke-width="3.5"/> - <path d="M21.283,38.05l-9.574,14.361" fill="none" id="path5530" stroke="&stroke_color;" stroke-linecap="round" stroke-width="3.5"/> - <path d="M29.834,38.05l-9.572,14.361" fill="none" id="path5532" stroke="&stroke_color;" stroke-linecap="round" stroke-width="3.5"/> - </g> -</g></svg> -EOF - -mkdir -m 755 -p /home/olpc/.local/share/applications - -cat << EOF > /home/olpc/.local/share/applications/etoys.desktop -#!/usr/bin/env xdg-open - -[Desktop Entry] -Type=Application -Name=Etoys -GenericName=The Etoys Environment -Comment=starts Etoys -Exec=etoys -Terminal=false -Icon=/usr/share/pixmaps/etoys.svg -StartupWMClass=squeak -Categories=Education; - -X-Desktop-File-Install-Version=0.16 -EOF -chown olpc:olpc /home/olpc/.local/share/applications/ -R - # disable the default loading of packagekit in gnome cat << EOF > /home/olpc/.config/autostart/gpk-update-icon.desktop [Desktop Entry] @@ -452,134 +317,7 @@ EOF chmod 666 /home/olpc/.config/autostart/gpk-update-icon.desktop chown olpc:olpc /home/olpc/.config/autostart/gpk-update-icon.desktop -# use config file for xulrunner/firefox -# works for firefox, won't start unless cfg file is present -# confirm browse/sugar works when using all.js -# Browse ignores what is in xulrunner but intl.accept_languages is ok -cat << EOF #> /usr/lib/firefox-3.6/defaults/preferences/loadcustom.js -// use a cfg file -pref("general.config.obscure_value", 0); -pref("general.config.filename", "olpc.cfg"); -EOF - -# create cfg file for firefox -# move to copying cfg from from git next -cat << EOF > /home/olpc/.config/olpc.cfg -// set defaults need more info here JV -lockPref("intl.accept_languages", "en-au,en-gb,en-us,en"); -defaultPref("signon.rememberSignons", false); -defaultPref("general.useragent.locale", "en-AU"); -defaultPref("spellchecker.dictionary", "en_AU"); -defaultPref("layout.spellcheckDefault", 2); -pref("browser.startup.homepage", "file:///home/olpc/.library_pages/index.html"); -pref("print.printer_PostScript/default.print_bgcolor", false); -pref("print.printer_PostScript/default.print_bgimages", false); -pref("print.printer_PostScript/default.print_colorspace", "default"); -pref("print.printer_PostScript/default.print_command", "lpr ${MOZ_PRINTER_NAME:+-P\"$MOZ_PRINTER_NAME\"}"); -pref("print.printer_PostScript/default.print_downloadfonts", false); -pref("print.printer_PostScript/default.print_edge_bottom", 0); -pref("print.printer_PostScript/default.print_edge_left", 0); -pref("print.printer_PostScript/default.print_edge_right", 0); -pref("print.printer_PostScript/default.print_edge_top", 0); -pref("print.printer_PostScript/default.print_evenpages", true); -pref("print.printer_PostScript/default.print_footercenter", ""); -pref("print.printer_PostScript/default.print_footerleft", "&PT"); -pref("print.printer_PostScript/default.print_footerright", "&D"); -pref("print.printer_PostScript/default.print_headercenter", ""); -pref("print.printer_PostScript/default.print_headerleft", "&T"); -pref("print.printer_PostScript/default.print_headerright", "&U"); -pref("print.printer_PostScript/default.print_in_color", true); -pref("print.printer_PostScript/default.print_margin_bottom", "0.500000012107193"); -pref("print.printer_PostScript/default.print_margin_left", "0.500000012107193"); -pref("print.printer_PostScript/default.print_margin_right", "0.500000012107193"); -pref("print.printer_PostScript/default.print_margin_top", "0.500000012107193"); -pref("print.printer_PostScript/default.print_oddpages", true); -pref("print.printer_PostScript/default.print_orientation", 0); -pref("print.printer_PostScript/default.print_pagedelay", 500); -pref("print.printer_PostScript/default.print_paper_data", 0); -pref("print.printer_PostScript/default.print_paper_height", "297.00"); -pref("print.printer_PostScript/default.print_paper_name", "iso_a4"); -pref("print.printer_PostScript/default.print_paper_size_type", 1); -pref("print.printer_PostScript/default.print_paper_size_unit", 1); -pref("print.printer_PostScript/default.print_paper_width", "210.00"); -pref("print.printer_PostScript/default.print_plex_name", "default"); -pref("print.printer_PostScript/default.print_resolution_name", "default"); -pref("print.printer_PostScript/default.print_reversed", false); -pref("print.printer_PostScript/default.print_scaling", " 1.00"); -pref("print.printer_PostScript/default.print_shrink_to_fit", true); -pref("print.printer_PostScript/default.print_to_file", false); -pref("print.printer_PostScript/default.print_to_filename", "/home/olpc/mozilla.ps"); -pref("print.printer_PostScript/default.print_unwriteable_margin_bottom", 56); -pref("print.printer_PostScript/default.print_unwriteable_margin_left", 25); -pref("print.printer_PostScript/default.print_unwriteable_margin_right", 25); -pref("print.printer_PostScript/default.print_unwriteable_margin_top", 25); -pref("print.tmp.printerfeatures.PostScript/default.can_change_colorspace", false); -pref("print.tmp.printerfeatures.PostScript/default.can_change_downloadfonts", false); -pref("print.tmp.printerfeatures.PostScript/default.can_change_jobtitle", false); -pref("print.tmp.printerfeatures.PostScript/default.can_change_num_copies", true); -pref("print.tmp.printerfeatures.PostScript/default.can_change_orientation", true); -pref("print.tmp.printerfeatures.PostScript/default.can_change_paper_size", true); -pref("print.tmp.printerfeatures.PostScript/default.can_change_plex", false); -pref("print.tmp.printerfeatures.PostScript/default.can_change_printincolor", true); -pref("print.tmp.printerfeatures.PostScript/default.can_change_resolution", false); -pref("print.tmp.printerfeatures.PostScript/default.can_change_spoolercommand", true); -pref("print.tmp.printerfeatures.PostScript/default.colorspace.0.name", "default"); -pref("print.tmp.printerfeatures.PostScript/default.colorspace.count", 1); -pref("print.tmp.printerfeatures.PostScript/default.has_special_printerfeatures", true); -pref("print.tmp.printerfeatures.PostScript/default.orientation.0.name", "portrait"); -pref("print.tmp.printerfeatures.PostScript/default.orientation.1.name", "landscape"); -pref("print.tmp.printerfeatures.PostScript/default.orientation.count", 2); -pref("print.tmp.printerfeatures.PostScript/default.paper.0.height_mm", 210); -pref("print.tmp.printerfeatures.PostScript/default.paper.0.is_inch", false); -pref("print.tmp.printerfeatures.PostScript/default.paper.0.name", "A5"); -pref("print.tmp.printerfeatures.PostScript/default.paper.0.width_mm", 148); -pref("print.tmp.printerfeatures.PostScript/default.paper.1.height_mm", 297); -pref("print.tmp.printerfeatures.PostScript/default.paper.1.is_inch", false); -pref("print.tmp.printerfeatures.PostScript/default.paper.1.name", "A4"); -pref("print.tmp.printerfeatures.PostScript/default.paper.1.width_mm", 210); -pref("print.tmp.printerfeatures.PostScript/default.paper.2.height_mm", 420); -pref("print.tmp.printerfeatures.PostScript/default.paper.2.is_inch", false); -pref("print.tmp.printerfeatures.PostScript/default.paper.2.name", "A3"); -pref("print.tmp.printerfeatures.PostScript/default.paper.2.width_mm", 297); -pref("print.tmp.printerfeatures.PostScript/default.paper.3.height_mm", 279); -pref("print.tmp.printerfeatures.PostScript/default.paper.3.is_inch", true); -pref("print.tmp.printerfeatures.PostScript/default.paper.3.name", "Letter"); -pref("print.tmp.printerfeatures.PostScript/default.paper.3.width_mm", 215); -pref("print.tmp.printerfeatures.PostScript/default.paper.4.height_mm", 355); -pref("print.tmp.printerfeatures.PostScript/default.paper.4.is_inch", true); -pref("print.tmp.printerfeatures.PostScript/default.paper.4.name", "Legal"); -pref("print.tmp.printerfeatures.PostScript/default.paper.4.width_mm", 215); -pref("print.tmp.printerfeatures.PostScript/default.paper.5.height_mm", 431); -pref("print.tmp.printerfeatures.PostScript/default.paper.5.is_inch", true); -pref("print.tmp.printerfeatures.PostScript/default.paper.5.name", "Tabloid"); -pref("print.tmp.printerfeatures.PostScript/default.paper.5.width_mm", 279); -pref("print.tmp.printerfeatures.PostScript/default.paper.6.height_mm", 254); -pref("print.tmp.printerfeatures.PostScript/default.paper.6.is_inch", true); -pref("print.tmp.printerfeatures.PostScript/default.paper.6.name", "Executive"); -pref("print.tmp.printerfeatures.PostScript/default.paper.6.width_mm", 190); -pref("print.tmp.printerfeatures.PostScript/default.paper.count", 7); -pref("print.tmp.printerfeatures.PostScript/default.plex.0.name", "default"); -pref("print.tmp.printerfeatures.PostScript/default.plex.count", 1); -pref("print.tmp.printerfeatures.PostScript/default.resolution.0.name", "default"); -pref("print.tmp.printerfeatures.PostScript/default.resolution.count", 1); -pref("print.tmp.printerfeatures.PostScript/default.supports_colorspace_change", false); -pref("print.tmp.printerfeatures.PostScript/default.supports_downloadfonts_change", false); -pref("print.tmp.printerfeatures.PostScript/default.supports_jobtitle_change", false); -pref("print.tmp.printerfeatures.PostScript/default.supports_orientation_change", true); -pref("print.tmp.printerfeatures.PostScript/default.supports_paper_size_change", true); -pref("print.tmp.printerfeatures.PostScript/default.supports_plex_change", false); -pref("print.tmp.printerfeatures.PostScript/default.supports_printincolor_change", true); -pref("print.tmp.printerfeatures.PostScript/default.supports_resolution_change", false); -pref("print.tmp.printerfeatures.PostScript/default.supports_spoolercommand_change", true); - -EOF - -#ln -sf /home/olpc/.config/olpc.cfg /usr/lib/firefox-3.6/olpc.cfg - -# use sugar homepage for firefox button -#echo "file:///home/olpc/.library_pages/index.html" > /usr/lib/firefox-3.6/browserconfig.properties - -# chown the directories added in post-custom-75 setAU.sh step +# chown the directories added in post-custom-80 setAU.sh step #chown -R olpc:olpc /home/olpc/.config #chown -R olpc:olpc /home/olpc/.gimp-2.6 #chown -R olpc:olpc /home/olpc/.AbiSuite @@ -619,7 +357,8 @@ chmod 0777 /etc/ntp chmod 0777 /etc/ntp/step-tickers # switch to the Addons repo for new/updated activities. -sed -i -e 's=11.3.1=11.3.1/Addons=' /home/olpc/Activities/.groups +sed -i -e 's=ARM=ARM-Addons=' /home/olpc/Activities/.groups +sed -i -e 's=i386=i386-Addons=' /home/olpc/Activities/.groups # disable the below for a standard build # Set gconf keys @@ -642,8 +381,7 @@ gconftool-2 --set --type=bool /desktop/sugar/feedback/personalized_submit 0 #gconftool-2 --set --type=bool /desktop/sugar/feedback/anonymous_with_sn 1 #gconftool-2 --set --type=int /desktop/sugar/feedback/anonymous_delay 30 -gconftool-2 --set --type=bool /desktop/sugar/power/extreme_management_enabled 0 -gconftool-2 --set --type=bool /desktop/sugar/show_register 0 +#gconftool-2 --set --type=bool /desktop/sugar/show_register 0 EOF # run gconf.info as olpc |