tazpanel rev 30
live.cgi: Add support to tazUSB gen-liveusb
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Tue Apr 05 05:09:53 2011 +0200 (2011-04-05) |
parents | 167d42c156fa |
children | 253219c1f9fe |
files | live.cgi |
line diff
1.1 --- a/live.cgi Tue Apr 05 03:35:45 2011 +0200 1.2 +++ b/live.cgi Tue Apr 05 05:09:53 2011 +0200 1.3 @@ -24,10 +24,16 @@ 1.4 1.5 case "$QUERY_STRING" in 1.6 write-iso=*) 1.7 - COMPRESSION=${QUERY_STRING#write-iso=} 1.8 + comp=${QUERY_STRING#write-iso=} 1.9 xterm $XTERM_OPTS \ 1.10 - -title "write-iso" \ 1.11 - -e "tazlito writeiso $COMPRESSION" & ;; 1.12 + -T "write-iso" \ 1.13 + -e "tazlito writeiso $comp" & ;; 1.14 + gen-liveusb=*) 1.15 + dev=`httpd -d ${QUERY_STRING#gen-liveusb=}` 1.16 + xterm $XTERM_OPTS \ 1.17 + -T "Tazusb gen-liveusb" \ 1.18 + -e "tazusb gen-liveusb $dev; \ 1.19 + gettext \"ENTER to quit\"; read i" & ;; 1.20 *) 1.21 continue ;; 1.22 esac 1.23 @@ -53,11 +59,12 @@ 1.24 <p>`gettext "Create and manage Live CD or USB SliTaz systems"`<p> 1.25 </div> 1.26 1.27 -<h3>`gettext "Write an ISO"`</h3> 1.28 +<h3>`gettext "Write a Live CD"`</h3> 1.29 <p> 1.30 - `gettext "Writeiso will generate an ISO image of the current filesystem 1.31 - as is, including the /home directory. It is an easy way to remaster a 1.32 - SliTaz Live system, you just have to: boot, modify, writeiso."` 1.33 + `gettext "The command writeiso will generate an ISO image of the 1.34 + current filesystem as is, including all files in the /home directory. 1.35 + It is an easy way to remaster a SliTaz Live system, you just have 1.36 + to: boot, modify, writeiso."` 1.37 </p> 1.38 <form method="get" action="$SCRIPT_NAME"> 1.39 `gettext "Compression type:"` 1.40 @@ -67,7 +74,31 @@ 1.41 <option value="none">none</option> 1.42 </select> 1.43 <input type="submit" value="`gettext "write ISO"`" /> 1.44 -</form 1.45 +</form> 1.46 + 1.47 +<h3>`gettext "Live USB"`</h3> 1.48 +<p> 1.49 + `gettext "Generate SliTaz LiveUSB media and boot in RAM! Insert a 1.50 + LiveCD into the cdrom drive, select the correct device and press 1.51 + Generate."` 1.52 +</p> 1.53 +<form method="get" action="$SCRIPT_NAME"> 1.54 + `gettext "USB Media to use:"` 1.55 + <select name="gen-liveusb"> 1.56 +EOT 1.57 + # List disk if plugged USB device 1.58 + if [ -d /proc/scsi/usb-storage ]; then 1.59 + for i in `blkid | cut -d ":" -f 1`; do 1.60 + echo "<option value='$i'>$i</option>" 1.61 + done 1.62 + else 1.63 + echo "<option value="">"`gettext "Not found"`"</option>" 1.64 + fi 1.65 + cat << EOT 1.66 + </select> 1.67 + <input type="submit" value="`gettext "generate"`" /> 1.68 +</form> 1.69 + 1.70 EOT 1.71 ;; 1.72 esac