http://paperlined.org/apps/slax/PXE_booting/remaster_slax_initrd.sh
#!/bin/bash
# Download slax-6.x.x.tar to the same directory as this script before running it
# http://www.slax.org/get_slax.php
# You must be root to run this script.
# This uses the "@@" syntax in the way that JAR files use it. That is,
# "@@" signifies that the file being looked at resides *inside* of the
# given archive file.
# NOTE: unlike what another script implies
# http://www.slax.org/forum.php?action=view&parentID=367
# httpfs is already INCLUDED in the stock initrd. (as of SLAX v6.1.2)
# So you don't need to remaster the initrd if that's what you're
# looking for.
TOPDIR=$PWD
##############################[ CLEAN ]###########################
rm -rf -- slax.tar@@
umount /mnt/
##############################[ EXTRACT ]###########################
mkdir slax.tar@@/
cd $TOPDIR/slax.tar@@/
tar -xvf ../slax-6.1.2.tar
cd $TOPDIR/slax.tar@@/boot/
gzip -dc initrd.gz > .initrd
mount -o loop .initrd /mnt
mkdir initrd.gz@@/
cd $TOPDIR/slax.tar@@/boot/initrd.gz@@/
cp -rpv /mnt/* .
umount /mnt/; rm $TOPDIR/slax.tar@@/boot/.initrd
##############################[ MAKE CHANGES ]###########################
# TODO: where do I copy the 001-core.lzm and other .lzm files, to make sure they're loaded?
# Documentation from Thomas M himself:
# http://www.slax.org/forum.php?action=view&parentID=17378#postid18504
##############################[ RE-PACKAGE ]###########################
# TODO: see http://www.nongnu.org/lpi-manuals/lpi-201/html/ch02s03.html#id290544
Generated by GNU enscript 1.6.4.