Set BOOTDIR path and run after setting password "passwd". Requires "advcomp.tcz/e"
Script for tc_2.3
edits /boot/tinycore.gz (assumes iso is already unpacked)
edit: changed to more reliable test
#!/bin/ash
### Define directories##
###First set password with "passwd"
### Add "etc/passwd" "etc/shadow" to /opt/.filetool.lst
## requires "advcomp.tcz"
#### SET PATH to boot directory
BOOTDIR=""
#BOOTDIR="/mnt/hda3/tinycore2/boot"
if [ -z $BOOTDIR ]; then
echo "set BOOTDIR"
exit 2
fi
sudo mkdir /tmp/extract
WORKDIR="/tmp/extract"
## Make backup, extract tinycore.gz
cd $WORKDIR
zcat $BOOTDIR/tinycore.gz | sudo cpio -i -H newc -d
sudo mv $BOOTDIR/tinycore.gz $BOOTDIR/tinycore.gz.bak
## edit
echo "working..................."
sudo sed -i 's/--autologin root//' etc/inittab
### Repack ####
find | sudo cpio -o -H newc | gzip -2 > ../tinycore.gz
sudo advdef -z4 ../tinycore.gz
sudo mv /tmp/tinycore.gz $BOOTDIR
exit 0