Den 2015-02-22 14:51, Israel skrev: > On 02/22/2015 06:17 AM, Nio Wiklund wrote: >> Den 2015-02-22 10:06, Nio Wiklund skrev: >>> Den 2015-02-22 05:35, Israel skrev: >>>> http://torios.net/tori-os-pre-beta/ >>>> PLEASE TEST THIS!!! >>>> >>> I'm downloading it :-P >>> >> Hi toriosadores :-) >> >> The iso file size is 677 Mibibytes, well within CD size. >> >> This pre-beta version works live and installed in my IBM Thinkpad T42 >> with Pentium M. >> >> tar needed exactly 100 seconds to expand the tarball to the root >> partition, which is quite good in such an old computer. >> >> After the second reboot htop shows 72 MB RAM used. >> >> Disk used shown by df -h is 1.7 G (Gibibytes) >> >> I have not tested much yet, but the 'welcome and warning' screen of the >> OBI does not look good. It is incompletely edited from the original, and >> gives a bad impression. See the attached picture. >> >> Best regards >> Nio > Hi Nio, > I did change it to add in the new option, what do you suggest I change > to make it more clear? > I wanted to make it very clear to new users that they must use the other > option to install it beside their current OS. > > Thank you for your feedback!!! > All of the other stuff is great!! >
Hi Israel, I attached my suggestion (a modified 'starter' file and a corresponding screenshot) Best regards Nio
#!/bin/bash # author sudodus alias nio-wiklund at launchpad # # date editor comment # 2013-11-08 sudodus upgraded starter (for the obi) # 2013-11-08 sudodus added dltbl (download tarball) # 2014-05-17 sudodus version for 9w without 'myself - 123456' # 2014-05-19 sudodus version for 9w without 'Download tarball' # 2014-06-18 sudodus version for 9w focused on OBI level # 2014-07-10 sudodus dynamic focus: tarball, OBI level, install # 2014-07-11 sudodus dynamic focus: defitem d, s, o, i # line 130 echoout(){ echo "[OBI] $@" echo "$@" >> "${HOME}"/obi-installer.log } LC_ALL=C;LANG=C #psw=torios obitxt="obi.txt" #hlptxt="/tmp/help-mkusb.txt" tiptxt="tips.txt" selected="selected" obilevel="obilevel" # check for tarballs if [ -d "/tarballs" ] then tarpath="/tarballs" elif [ -d "${HOME}/tarballs" ] then tarpath="${HOME}/tarballs" elif [ -d "${PWD}/tarballs" ] then tarpath="${PWD}/tarballs" else tarpath="${PWD}" echoout "Error finding the tarball path using: ${PWD}" fi echoout "Tarball path: $tarpath" source functions if [ -f "/home/$USER/obi.txt" ] then dpath="/home/$USER" elif [ -f "${HOME}/obi.txt" ] then dpath="${HOME}" elif [ -f "${PWD}/obi.txt" ] then dpath="${PWD}" elif [ -f /usr/share/OBI/obi.txt ] then dpath="/usr/share/OBI/" else echoout "Text not found. Change directory!" exit 1 fi if [ "obi$DISPLAY" == "obi" ] then mktar="mktbl" else mktar="zmktbl" fi echoout "Using $mktar to make the tarballs" if [ -x "/usr/bin/$mktar" ] then mktblpath="/usr/bin" else mktblpath="${dpath}" fi echoout "OBI path: $dpath" obitxt="$dpath/$obitxt" prgnam="One Button Installer" ## Ubuntu ONLY version number APTCACHE=$(which apt-cache) if [ ! -z "${APTCACHE}" ] then ver_no=$(apt-cache policy one-button-installer | grep Installed: | sed 's/Installed://' | sed 's/ubuntu.*//') version="$prgnam $ver_no" else ## if we can't find apt-cache to grep the version just display the program name version="$prgnam" fi dialog --backtitle "$version - Splash" \ --timeout 3 --exit-label "OK" --textbox "$obitxt" 0 0 ##Took this out for OEM install #User and password for installed system\n # User: \Z4$psw\Zn\n # Password: \Z4$psw\Zn\n dialog --colors --no-shadow \ --backtitle "$version - Welcome and Warning" --msgbox \ "Welcome,\n Installing an operating system is a \Z1risky\Zn operation.\n \n WARNING \Z1Copy the data you want to keep to another device\Zn, for example\n WARNING an external hard disk drive or a cloud service! Otherwise,\n WARNING there might be no easy way to recover any previous data.\n WARNING Expensive intelligence services might restore some data.\n WARNING\n WARNING \Z1If you use the BASIC installer the target device will be\Zn\n WARNING \Z1********** COMPLETELY OVERWRITTEN **********\Zn\n WARNING\n WARNING \Z1If you want to keep an installed operating system,\Zn\n WARNING make sure to use the option\n WARNING \Z1'Partition drives and Install alongside current OS'\Zn" \ 0 0 #18 70 #0 0 #read -sn1 if [ -f "/home/$USER/mkhelp" ] then dpath="/home/$USER" elif [ -f "$PWD/mkhelp" ] then dpath="$PWD" elif [ -f "${HOME}/mkhelp" ] then dpath="${HOME}" elif [ -f "/usr/share/OBI/mkhelp" ] then dpath="/usr/share/OBI" else echo "Script not found. Change directory!" fi sudo "$dpath/init-dialog" tiptxt="$dpath/$tiptxt" # check for selected if [ -f /usr/share/OBI/selected ] then selected="/usr/share/OBI/selected" elif [ -f "$HOME/selected" ] then selected="$HOME/selected" elif [ -d "$PWD/selected" ] then selected="$PWD/selected" else selected="selected" echoout "Error finding the OBI selected path" fi ## Test to see if the tarball in 'selected' exists first selectedtest=$(cat "${selected}") if [ ! -f "${selectedtest}" ] then ## if it doesn't pick the last one listed so there is some reasonable choice available for i in "${tarpath}"/*.tar.[gx]z do target="$i" done echoout "Had to find a tarball.. OBI found $target" # write tarball name echo "$target" > "$selected" fi ans="dummy" while [ "$ans" != "q" ] && [ "$ans" != "" ] do ls -1 "${tarpath}"/*.tar.[gx]z > /dev/null 2> /dev/null if [ $? -ne 0 ] then sudo rm "$selected" tarball= menutitle="No tarball selected" defitem=d else grep "tar.[gx]z" "$selected" > /dev/null 2> /dev/null if [ $? -ne 0 ] then sudo rm "$selected" fi if test -s "$selected" then tarball=$(cat "${selected}") thisOS=$(basename "${tarball/.tar*/}") if [ "$thisOS" == "ball" ] then echoout "Unlabeled OS to install: $thisOS" menutitle="Unlabeled OS to install: $thisOS" ##Check tarball name else echoout "OS to install: $thisOS" menutitle="OS to install: $thisOS" fi if test -s "$obilevel" then read level < "$obilevel" defitem=i else level=basic defitem=o fi else tarball= menutitle="No tarball selected" defitem=s fi fi echoout "Menu Title: $menutitle" cd "$dpath" ans=$(dialog --no-shadow --backtitle "$version - Starter Menu" \ --title "Please select an action with a letter key or the arrow keys" \ --default-item "$defitem" --colors --cancel-label Quit --menu "$menutitle" 18 76 11 \ s " Select tarball to install" \ a " Partition drives and Install alongside current OS" \ i " Install tarball \Z1with the $prgnam\Zn" \ d " Download tarball" \ m " Make tarball" \ o " $level OBI level (select basic or advanced)" \ h " Help to select drive" \ t " Tips" \ c " Check (and repair) the file system /dev/sda1" \ q " Quit from this menu (exit to the bash shell or close window)" \ r " Reboot" \ p " Poweroff" \ 3>&1 1>&2 2>&3 3>&- ) # read -n 1 -s ans if [ "$ans" == "s" ] then sudo "$dpath/select-tarball" elif [ "$ans" == "a" ] then echo "advanced" | sudo tee $obilevel sudo "$dpath/partition-help" sudo gparted && sudo "$dpath/obi" elif [ "$ans" == "i" ] then sudo "$dpath/obi" elif [ "$ans" == "d" ] then sudo "$dpath/dltbl" elif [ "$ans" == "m" ] then sudo "$mktblpath/$mktar" #changed to use zenity mktbl IF X $DISPLAY is active elif [ "$ans" == "o" ] then sudo "$dpath/setlevel" elif [ "$ans" == "h" ] then sudo "$dpath/mkhelp" elif [ "$ans" == "t" ] then dialog --backtitle "$version - Tips (use arrow keys to scroll)" \ --textbox "$tiptxt" 17 76 elif [ "$ans" == "c" ] then sudo umount /dev/sda1 sudo e2fsck -f /dev/sda1 elif [ "$ans" == "r" ] then sudo reboot elif [ "$ans" == "p" ] then sudo poweroff fi done
-- Mailing list: https://launchpad.net/~torios Post to : torios@lists.launchpad.net Unsubscribe : https://launchpad.net/~torios More help : https://help.launchpad.net/ListHelp