# HG changeset patch # User Antoine Bodin # Date 1300165743 -3600 # Node ID 68435a9c08439cb694b5256c85108c2fe9067ee6 # Parent 97ba499fdb2cf661c941b8301302c40666816e51 clean-up code: removing trailing spaces diff -r 97ba499fdb2c -r 68435a9c0843 COPYING --- a/COPYING Tue Mar 15 06:08:30 2011 +0100 +++ b/COPYING Tue Mar 15 06:09:03 2011 +0100 @@ -9,17 +9,17 @@ -------- Les slitaz-boot-scripts des scripts libre ; vous pouvez les redistribuer et/ou -les modifier conformément aux dispositions de la Licence Publique Générale GNU, -telle que publiée par la Free Software Foundation ; version 3 de la +les modifier conformément aux dispositions de la Licence Publique Générale GNU, +telle que publiée par la Free Software Foundation ; version 3 de la licence, ou encore (à votre choix) toute version ultérieure. Les slitaz-boot-scripts sont distribués dans l'espoir qu'il sera utile, mais -SANS AUCUNE GARANTIE ; sans même la garantie implicite de COMMERCIALISATION ou -D'ADAPTATION À UN OBJET PARTICULIER. Pour plus de détails, voir la Licence +SANS AUCUNE GARANTIE ; sans même la garantie implicite de COMMERCIALISATION ou +D'ADAPTATION À UN OBJET PARTICULIER. Pour plus de détails, voir la Licence Publique Générale GNU. -Un exemplaire de la Licence Publique Générale GNU doit être fourni avec -slitaz-boot-scripts si ce n'est pas le cas, écrivez à la Free Software +Un exemplaire de la Licence Publique Générale GNU doit être fourni avec +slitaz-boot-scripts si ce n'est pas le cas, écrivez à la Free Software Foundation Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA @@ -33,7 +33,7 @@ Slitaz-boot-scripts 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 +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 diff -r 97ba499fdb2c -r 68435a9c0843 README --- a/README Tue Mar 15 06:08:30 2011 +0100 +++ b/README Tue Mar 15 06:09:03 2011 +0100 @@ -1,4 +1,4 @@ -README for slitaz-boot-scripts +README for slitaz-boot-scripts =============================================================================== diff -r 97ba499fdb2c -r 68435a9c0843 etc/init.d/bootopts.sh --- a/etc/init.d/bootopts.sh Tue Mar 15 06:08:30 2011 +0100 +++ b/etc/init.d/bootopts.sh Tue Mar 15 06:09:03 2011 +0100 @@ -5,7 +5,7 @@ # . /etc/init.d/rc.functions -# Update fstab for swapon/swapoff +# Update fstab for swapon/swapoff add_swap_in_fstab() { grep -q "$1 " /etc/fstab || cat >> /etc/fstab < /etc/keymap.conf status ;; home=*) - # Check for a specified home partition (home=*) and check for + # Check for a specified home partition (home=*) and check for # user home dir. Note: home=usb is a shorter and easier way to # have home=/dev/sda1. DEVICE=${opt#home=} @@ -129,8 +129,8 @@ else rm -rf /tmp/$USER-files fi - # Install all packages in /home/boot/packages. In live CD and - # USB mode the option home= mounts the device on /home, so we + # Install all packages in /home/boot/packages. In live CD and + # USB mode the option home= mounts the device on /home, so we # already have a boot directory with the Kernel and rootfs. if [ -d "/home/boot/packages" ]; then for pkg in /home/boot/packages/*.tazpkg @@ -150,7 +150,7 @@ do modprobe $mod done - grep -qs batt /etc/lxpanel/default/panels/panel || + grep -qs batt /etc/lxpanel/default/panels/panel || sed -i 's/= cpu/= batt\n}\n\nPlugin {\n type = cpu/' \ /etc/lxpanel/default/panels/panel 2> /dev/null # Enable Kernel Laptop mode. @@ -171,7 +171,7 @@ fi done ;; mount-packages) - # Mount and install packages-XXX.iso (useful without Internet + # Mount and install packages-XXX.iso (useful without Internet # connection). PKGSIGN="LABEL=\"packages-$(cat /etc/slitaz-release)\" TYPE=\"iso9660\"" PKGDEV=$(blkid | grep "$PKGSIGN" | cut -d: -f1) diff -r 97ba499fdb2c -r 68435a9c0843 etc/init.d/network.sh --- a/etc/init.d/network.sh Tue Mar 15 06:08:30 2011 +0100 +++ b/etc/init.d/network.sh Tue Mar 15 06:09:03 2011 +0100 @@ -5,9 +5,9 @@ . /etc/init.d/rc.functions if [ -z "$2" ]; then - . /etc/network.conf + . /etc/network.conf else - . $2 + . $2 fi @@ -21,13 +21,13 @@ echo -n "Configuring loopback..." /sbin/ifconfig lo 127.0.0.1 up /sbin/route add 127.0.0.1 lo - status + status } eth() { # Use ethernet - ifconfig $INTERFACE up + ifconfig $INTERFACE up } wifi() { @@ -35,7 +35,7 @@ # essid any will work and the interface is autodetected. if [ "$WIFI" = "yes" ] || grep -q "wifi" /proc/cmdline; then ifconfig $INTERFACE down - + # Confirm if $WIFI_INTERFACE is the wifi interface if [ ! -d /sys/class/net/$WIFI_INTERFACE/wireless ]; then echo "$WIFI_INTERFACE is not a wifi interface, changing it." @@ -45,33 +45,33 @@ done) [ -n "$WIFI_INTERFACE" ] && sed -i "s/^WIFI_INTERFACE=.*/WIFI_INTERFACE=\"$WIFI_INTERFACE\"/" /etc/network.conf fi - + echo -n "Configuring $WIFI_INTERFACE..." ifconfig $WIFI_INTERFACE up if iwconfig $WIFI_INTERFACE | grep -q "Tx-Power"; then iwconfig $WIFI_INTERFACE txpower on fi status - + [ -n "$WPA_DRIVER" ] || WPA_DRIVER="wext" - - + + IWCONFIG_ARGS="" [ -n "$WIFI_MODE" ] && IWCONFIG_ARGS="$IWCONFIG_ARGS mode $WIFI_MODE" [ -n "$WIFI_CHANNEL" ] && IWCONFIG_ARGS="$IWCONFIG_ARGS channel $WIFI_CHANNEL" # unencrypted network - if [ "$WIFI_KEY" == "" -o "$WIFI_KEY_TYPE" == "none" ]; + if [ "$WIFI_KEY" == "" -o "$WIFI_KEY_TYPE" == "none" ]; then iwconfig $WIFI_INTERFACE essid "$WIFI_ESSID" $IWCONFIG_ARGS fi # encrypted network [ -n "$WIFI_KEY" ] && case "$WIFI_KEY_TYPE" in - wep|WEP) + wep|WEP) IWCONFIG_ARGS="$IWCONFIG_ARGS key $WIFI_KEY" iwconfig $WIFI_INTERFACE essid "$WIFI_ESSID" $IWCONFIG_ARGS # wpa_supplicant can also deal with wep encryption but iwconfig is preferred # Tip: Use unquoted strings for hexadecimal key in wep_key0 -# cat /etc/wpa_supplicant.conf > /tmp/wpa.conf +# cat /etc/wpa_supplicant.conf > /tmp/wpa.conf # cat >> /tmp/wpa.conf < /tmp/wpa.conf # load pre-configured multiple profiles + wpa|WPA) cat /etc/wpa_supplicant.conf > /tmp/wpa.conf # load pre-configured multiple profiles cat >> /tmp/wpa.conf < /tmp/wpa.conf + any|ANY) cat /etc/wpa_supplicant.conf > /tmp/wpa.conf cat >> /tmp/wpa.conf </dev/null - + if iwconfig $WIFI_INTERFACE | grep -q "Tx-Power"; then echo "Shutting down wifi card" iwconfig $WIFI_INTERFACE txpower off @@ -189,11 +189,11 @@ Start() { eth wifi - dhcp + dhcp static_ip # change default lxpanel panel iface [ -f /etc/lxpanel/default/panels/panel ] \ - && sed -i "s/iface=.*/iface=$INTERFACE/" /etc/lxpanel/default/panels/panel + && sed -i "s/iface=.*/iface=$INTERFACE/" /etc/lxpanel/default/panels/panel } diff -r 97ba499fdb2c -r 68435a9c0843 etc/init.d/rcS --- a/etc/init.d/rcS Tue Mar 15 06:08:30 2011 +0100 +++ b/etc/init.d/rcS Tue Mar 15 06:09:03 2011 +0100 @@ -1,5 +1,5 @@ #!/bin/sh -# /etc/init.d/rcS - Initial boot script for SliTaz GNU/Linux. +# /etc/init.d/rcS - Initial boot script for SliTaz GNU/Linux. # Config file is : /etc/rcS.conf # # rcS is the main initialization script used to check fs, mount, clean, @@ -118,7 +118,7 @@ /bin/chmod 1777 /tmp/.X11-unix /tmp/.ICE-unix status -# Fast boot into X for HD install or custom Live system. We need +# Fast boot into X for HD install or custom Live system. We need # keymap settings since Xvesa dumps the console mapping and a correct # slim configuration for screen resolution. DBUS and HAL must also start # before X session (manual login or autologin) to have devices in PCmanFM. @@ -160,17 +160,17 @@ [ "$FBSPLASH" == "yes" ] && echo "50" > /etc/fbsplash/fifo -# Handle kernel cmdline parameter modprobe= +# Handle kernel cmdline parameter modprobe= if [ -n "$MODPROBE" ]; then MODULES=`sed -e 's/.* modprobe=\([^ ]*\).*/\1/' -e 's/,/\n/g' < /proc/cmdline` for i in $MODULES; do echo -n "Loading kernel module $i" /sbin/modprobe $i - status + status done fi -# Handle kernel cmdline parameter config=, to source a +# Handle kernel cmdline parameter config=, to source a # disk init script if [ -n "$CONFIG" ]; then DEVICE=${CONFIG%,*} @@ -192,7 +192,7 @@ . /mnt/$SCRIPT /bin/umount /mnt 2> /dev/null || true fi - status + status fi # Mount /proc/bus/usb. @@ -246,7 +246,7 @@ [ "$FBSPLASH" == "yes" ] && echo "90" > /etc/fbsplash/fifo -# Re-source main config file. In Live mode, daemons list can be modified +# Re-source main config file. In Live mode, daemons list can be modified # by boot options (screen=text will remove slim). . /etc/rcS.conf diff -r 97ba499fdb2c -r 68435a9c0843 etc/init.d/wpa_action.sh --- a/etc/init.d/wpa_action.sh Tue Mar 15 06:08:30 2011 +0100 +++ b/etc/init.d/wpa_action.sh Tue Mar 15 06:09:03 2011 +0100 @@ -1,9 +1,9 @@ #!/bin/sh INTERFACE=$1 - + # For a dynamic IP with DHCP. if [ "$2" = "CONNECTED" ]; then - [ -f /var/run/udhcpc.$INTERFACE.pid] && killall udhcpc + [ -f /var/run/udhcpc.$INTERFACE.pid] && killall udhcpc /sbin/udhcpc -b -i $INTERFACE -p /var/run/udhcpc.$INTERFACE.pid elif [ "$2" = "DISCONNECTED" ]; then /sbin/udhcpc -b -i $INTERFACE -p /var/run/udhcpc.$INTERFACE.pid diff -r 97ba499fdb2c -r 68435a9c0843 etc/inittab --- a/etc/inittab Tue Mar 15 06:08:30 2011 +0100 +++ b/etc/inittab Tue Mar 15 06:09:03 2011 +0100 @@ -11,7 +11,7 @@ tty5::respawn:/sbin/getty 38400 tty5 tty6::respawn:/sbin/getty 38400 tty6 -# Stuff to do when restarting the init +# Stuff to do when restarting the init # process, or before rebooting. ::restart:/etc/init.d/rc.shutdown ::restart:/sbin/init diff -r 97ba499fdb2c -r 68435a9c0843 etc/rcS.conf --- a/etc/rcS.conf Tue Mar 15 06:08:30 2011 +0100 +++ b/etc/rcS.conf Tue Mar 15 06:09:03 2011 +0100 @@ -13,7 +13,7 @@ # /etc/fstab. Example: CHECK_FS="/dev/hda5 /dev/hdb1" CHECK_FS="" -# Fast boot into X by setting the system keymap-locale and starting +# Fast boot into X by setting the system keymap-locale and starting # the Slim login manager earlier at boot time. If fast X is enabled # then dbus, hald and slim can be removed from RUN_DAEMONS. FAST_BOOT_X="no"