slitaz-forge view mirror/floppies/mkfdrolling.sh @ rev 692
revision of german messages
author | Hans-G?nter Theisgen |
---|---|
date | Mon Oct 09 17:09:00 2017 +0100 (2017-10-09) |
parents | 4ea260d6c590 |
children | 2f42ab2912be |
line source
1 #!/bin/sh
3 WD=$(cd $(dirname $0); pwd)
4 while read name iso; do
5 cd $WD/$name
6 ISO=../../$iso
7 if [ ! -s fd001.img ] || [ $ISO -nt fd001.img ]; then
8 rm -f fd* 2> /dev/null
9 taziso $ISO floppyset > /dev/null
10 md5sum fd* > md5sum
11 mnt=/mnt$$
12 mkdir $mnt
13 mount -o loop,ro $ISO $mnt
14 mtime=$(stat -c %y $mnt/md5sum | sed 's/ .*//')
15 set -- $(sed '/ifmem/!d;s/.*ifmem //' $mnt/boot/isolinux/isolinux.cfg \
16 | sed 's|^|echo |;s|\([0-9][0-9]*\) |$((\1/1024))M |g' | sh)
17 umount $mnt
18 rmdir $mnt
19 echo "Built on $mtime, needs up to ${1}b of RAM" > title
20 n=0; x=1; while [ -n "$x" ]; do n=$(($n+2)); eval x=\$$n; done
21 n=$((($n - 2) / 2))
22 cat > description.html <<EOT
23 <p>You can start with one of the $n following flavors:</p>
25 <ul>
26 EOT
27 i=0
28 while [ $i -lt $n ]; do
29 eval flavor=\$$((($n - $i)*2))
30 eval ram=\$$((($n - $i)*2 -1))
31 cat >> description.html <<EOT
32 <li><b>$flavor</b> needs ${ram}B of RAM and $(ls fd* | \
33 awk "/fd$(($i+1))/{q=1}{if(!q)n++}END{print n}") floppies:
34 <tt>fd001.img</tt> to <tt>$(ls -r fd${i}* | sed q)</tt>.<br>
35 $flavor provides $(while read f d; do
36 [ $f == $flavor ] && echo $d; done <<EOT
37 base the minimum SliTaz distribution subset in text mode
38 justx the minimum SliTaz distribution subset with X11 support
39 gtkonly the minimum SliTaz distribution subset with GTK+ support
40 core the default SliTaz distribution
41 EOT
42 ).</li>
43 EOT
44 i=$(($i+1))
45 done
46 cat >> description.html <<EOT
47 </ul>
49 <p>Start your computer with <tt>fd001.img</tt>. It will show the kernel version
50 string and the kernel cmdline line. You can edit the cmdline. Most users can
51 just press Enter.</p>
53 <p>The floppy is then loaded into memory (one dot each 64KB) and you will be
54 prompted to insert the next floppy, <tt>fd002.img</tt>. And so on up to last
55 floppy.</p>
57 <p>You will be prompted to insert extra floppies for the next flavors.
58 You can bypass this by using B to boot without loading extra floppies.</p>
59 EOT
60 cd ..
61 ./mkindex.sh $name > index-$name.html
62 fi
63 done <<EOT
64 rolling iso/rolling/slitaz-rolling.iso
65 loram-rolling iso/rolling/slitaz-rolling-loram.iso
66 EOT