X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=ubuntu%2Fubuntu-cfg.sh;h=c14dcb9a7fafd78e62468a39d74cf18b3bcaa498;hb=b5bfb2006502b57fab234345a2393fd04e6d55ad;hp=bd1c9d3a6afc0c42d631a9e2d50f075d4b2c4b64;hpb=dcec87c5d26412332ea56c1ce39eef61b3a932af;p=hvlinux.git diff --git a/ubuntu/ubuntu-cfg.sh b/ubuntu/ubuntu-cfg.sh index bd1c9d3..c14dcb9 100755 --- a/ubuntu/ubuntu-cfg.sh +++ b/ubuntu/ubuntu-cfg.sh @@ -2,12 +2,11 @@ set -o errexit # Liste des items: -# 1. Installer "Broadcom STA wireless driver" (HP Mini 1115) -# 2. Désactiver touch CAPS LOCK +# 1. Désactiver touch CAPS LOCK GST=gstreamer0.10 -APT="sudo apt-get --yes" +APT="sudo apt-get --yes --force-yes" AGI="${APT} install" if [ "`id -u`" -eq 0 ]; then @@ -15,7 +14,45 @@ if [ "`id -u`" -eq 0 ]; then exit 1 fi -${APT} update +# On enlève les packages superflus + +# Purge Mono from my system! +if dpkg --list | grep "libmono" 1> /dev/null 2>&1; then + ${APT} purge libmono* cli-common +fi + +if dpkg --list | grep "bluez-gstreamer" 1> /dev/null 2>&1; then + ${APT} remove --purge bluetooth bluez bluez-gstreamer bluez-alsa bluez-cups +fi + +if dpkg --list | grep "openoffice" 1> /dev/null 2>&1; then + ${APT} remove --purge openoffice* +fi + +if dpkg --list | grep "samba-common" 1> /dev/null 2>&1; then + ${APT} remove --purge samba-common +fi + +if dpkg --list | grep "evolution-exchange" 1> /dev/null 2>&1; then + ${APT} remove --purge evolution +fi + +if dpkg --list | grep "pppconfig" 1> /dev/null 2>&1; then + ${APT} remove --purge pppconfig pppoeconf +fi + +if dpkg --list | grep "totem-common" 1> /dev/null 2>&1; then + ${APT} remove --purge totem totem-common +fi + +if dpkg --list | grep "gwibber" 1> /dev/null 2>&1; then + ${APT} remove --purge gwibber gwibber-service +fi + +# Remove proprietary code/drivers +if dpkg --list | grep "nvidia" 1> /dev/null 2>&1; then + ${APT} remove --purge nvidia-* +fi # Configuration SSH if [ ! -f ${HOME}/.ssh/id_dsa.pub ]; then @@ -30,44 +67,65 @@ sudo -u gdm gconftool-2 --set /desktop/gnome/sound/event_sounds --type bool fals # Ramener les boutons à droite dans les fenêtres Gtk+: gconftool-2 --set /apps/metacity/general/button_layout --type string menu:minimize,maximize,close +# Format horloge 24 heures +gconftool-2 --set /apps/panel/applets/clock_screen0/prefs/format --type string 24-hour + # Configuration de Nautilus - pas de preview pour ne pas ralentir gconftool-2 --set /apps/nautilus/preferences/preview_sound --type string never gconftool-2 --set /apps/nautilus/preferences/show_directory_item_counts --type string never gconftool-2 --set /apps/nautilus/preferences/show_icon_text --type string never gconftool-2 --set /apps/nautilus/preferences/show_image_thumbnails --type string never +gconftool-2 --set /apps/nautilus/preferences/media_automount_open --type bool false # Démarrage de Rhythmbox non minimisé gconftool-2 --set /apps/rhythmbox/plugins/status-icon/window-visible --type boolean true -# On enlève les packages superflus - -# Purge Mono from my system! -if dpkg --list | grep "libmono" 1> /dev/null 2>&1; then - ${APT} purge libmono* libgdiplus cli-common libglitz-glx1 libglitz1 -fi - -if dpkg --list | grep pulseaudio 1> /dev/null 2>&1; then - ${APT} remove --purge pulseaudio* -fi - -if dpkg --list | grep bluez-gstreamer 1> /dev/null 2>&1; then - ${APT} remove --purge bluetooth bluez bluez-gstreamer bluez-alsa bluez-cups -fi - +${APT} update ${APT} upgrade ${APT} dist-upgrade ${APT} autoremove +${APT} clean +${APT} autoclean + +# Configuration de GRUB +sudo sed -i -e 's!^\(GRUB_CMDLINE_LINUX_DEFAULT=\)"quiet splash"!\1"ipv6.disable=1"!' /etc/default/grub +sudo sed -i -e 's!^#\(GRUB_DISABLE_LINUX_RECOVERY="true"\)!\1!' /etc/default/grub +if ! grep "GRUB_DISABLE_OS_PROBER=\"true\"" /etc/default/grub 1> /dev/null 2>&1; then + echo 'GRUB_DISABLE_OS_PROBER="true"' | sudo tee --append /etc/default/grub +fi +sudo chmod -x /etc/grub.d/20_memtest86+ +# Change theme for custom theme +if [ -f /etc/grub.d/05_debian_theme ]; then + sudo rm /etc/grub.d/05_debian_theme +fi +cat << EOF | sudo tee /etc/grub.d/05_hugo_theme +#! /bin/sh +set -e + +echo "set menu_color_normal=green/black" +echo "set menu_color_highlight=light-green/black" +EOF +sudo chmod +x /etc/grub.d/05_hugo_theme +sudo update-grub -# localepurge is a simple script to recover diskspace wasted for unneeded locale files and localized man pages. +# localepurge recovers diskspace wasted for unneeded locale files and localized man pages. # It will automagically be invoked upon completion of any apt installation run. ${AGI} localepurge -${AGI} emacs23 -# Correction bug avec emacs: -# murrine_style_draw_box: assertion `height >= -1' failed -for subdir in Radiance Ambiance; do - sudo sed -i -e "s!\(GtkRange::trough-under-steppers =\) 0!\1 1!" /usr/share/themes/${subdir}/gtk-2.0/gtkrc -done +if lspci | grep "BCM43" 1> /dev/null 2>&1; then + if [ ! -f /etc/modprobe.d/b43.conf ]; then + sudo touch /etc/modprobe.d/b43.conf + echo "options b43 pio=1 qos=0" | sudo tee -a /etc/modprobe.d/b43.conf + ${AGI} b43-fwcutter + fi +fi + +${AGI} emacs + +${AGI} reiserfsprogs gparted + +# Connection serveurs NFS +${AGI} nfs-common portmap # Development ${AGI} build-essential texinfo gettext gawk bison flex @@ -75,37 +133,44 @@ ${AGI} autoconf autoconf-doc autotools-dev libtool ${AGI} manpages manpages-dev manpages-posix manpages-posix-dev # dockapp development -${AGI} libX11-dev libxpm-dev libxext-dev +${AGI} libx11-dev libxpm-dev libxext-dev ${AGI} libgtk2.0-dev libglib2.0-dev +# wmnotify uses SSL +${AGI} libssl-dev -# Vibro-Meter development -#${AGI} libncurses5-dev zlib1g-dev -# Pour opkg -#${AGI} libcurl4-gnutls-dev libgpgme11-dev -#${AGI} uncrustify -#sudo cpan XML::Parser +# Debian packaging +${AGI} dh-make lintian dupload ${AGI} subversion -# Servers -${AGI} nfs-common -#${AGI} ssh - ${AGI} abiword gnumeric gnumeric-plugins-extra ${AGI} texlive texlive-latex-recommended texlive-latex-extra texlive-humanities # Multimedia +${AGI} jackd patchage +${AGI} pulseaudio-module-jack +sudo adduser $(whoami) audio +# /etc/security/limits.d/audio.conf -> set rtprio from 95 to 99 ??? + ${AGI} libdvdread4 -sudo /usr/share/doc/libdvdread4/install-css.sh -${AGI} ${GST}-ffmpeg ${GST}-plugins-bad ${GST}-plugins-ugly -sudo add-apt-repository "deb http://www.getgnash.org/debs/ubuntu lucid main" -${AGI} mozilla-plugin-gnash ${GST}-fluendo-mp3 -${AGI} vlc vlc-plugin-jack mozilla-plugin-vlc -${AGI} sound-juicer +if [ ! -h /usr/lib/libdvdcss.so.2 ]; then + sudo /usr/share/doc/libdvdread4/install-css.sh +fi +${AGI} ffmpeg +${AGI} ${GST}-ffmpeg ${GST}-plugins-bad ${GST}-plugins-ugly ${GST}-fluendo-mp3 +${AGI} mozilla-plugin-gnash # Requires "mysql-common" +${AGI} vlc mozilla-plugin-vlc +if [ -h /dev/cdrom ]; then # Don't install on machines without CD/DVD-ROM + ${AGI} sound-juicer +fi # Musique ${AGI} vorbis-tools + ${AGI} timidity fluid-soundfont-gm fluid-soundfont-gs +# Désactivation de Timidity au démarrage (sytem-wide): +sudo sed -i -e 's!^# \(TIM_ALSASEQ=false\)!\1!' /etc/default/timidity +${AGI} easytag ${AGI} vkeybd ${AGI} audacity libmp3lame0 tap-plugins ${AGI} lilypond @@ -113,17 +178,31 @@ ${AGI} rosegarden ${AGI} sylpheed gconftool -s /desktop/gnome/url-handlers/mailto/command -t string "sylpheed --compose %s" +# Change location of default mail account from ~/Mail to ~/.mail +sed -i -e 's!^\( ${HOME}/GNUstep/Library/WindowMaker/autostart << "EOF" +#!/bin/sh +gnome-settings-daemon +EOF + chmod 755 ${HOME}/GNUstep/Library/WindowMaker/autostart +fi -# Desktop only -#${AGI} wmaker -#${AGI} pcmanfm +${AGI} pcmanfm +cat > ${HOME}/.gtkrc-2.0 << "EOF" +gtk-icon-theme-name="Tango" +gtk-enable-event-sounds=0 +gtk-enable-input-feedback-sounds=0 +EOF ${AGI} epdfview ${AGI} psutils ${AGI} gimp -if lspci | grep "nVidia" 1> /dev/null 2>&1; then - ${AGI} nvidia-settings nvidia-current -fi +${AGI} deborphan +sudo deborphan | xargs sudo apt-get -y remove --purge exit $?