Skip to content

Instantly share code, notes, and snippets.

@tryp
Created March 8, 2012 14:52
Show Gist options
  • Save tryp/2001358 to your computer and use it in GitHub Desktop.
Save tryp/2001358 to your computer and use it in GitHub Desktop.
make a filesystem.squashfs for use in casper liveCD/liveUSB images
#!/bin/sh
#
# make a filesystem.squashfs for use in casper liveCD/liveUSB images
# usage sudo ./do_squashfs rootdir
rm filesystem.squashfs
chroot $1 dpkg-query -W --showformat='${Package} ${Version}\n' > filesystem.manifest
mksquashfs $1 filesystem.squashfs
printf $(sudo du -sx --block-size=1 $1 | cut -f1) > filesystem.size
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment