Page 1 of 1

remasterpup3: new version of Puppy live-CD remaster script

Posted: Sat 15 May 2010, 15:04
by pa_mcclamrock
Just not in time for official Puppy 5.0 . . . :roll: I volunteered to keep up and (I hope) improve the Puppy live-CD remastering script; playdayz said "Great"; I made basically the following changes:

Code: Select all

# 2010 May 15 DMcC (remasterpup3): 
# changed one or two "OK" dialog boxes to "Yes/No" boxes;
# clarified and/or expanded language in several dialog boxes;
# added comments, whitespace, slight reorganization for readability of code;
# removed a bit of needless duplicated code (approx. lines 427-443 of original);
# added some user files to be automatically copied to /tmp/root and /tmp/etc;
# added progress display in rxvt during creation of /tmp/root.
The script still works the same as it did before. The big changes are in the text of dialog messages; I also added an rxvt window to show progress while /tmp/root is being squashed, since that takes longer than it used to. Here are some screenshots of the most-changed dialogs, and here are a few explanations:

In the box shown in "repup01.gif" (and a few places later on), I added explicit references to saving the ISO as a file rather than burning it to CD/DVD, if desired; added the clarifying expression "except for mounted external directories under /mnt" after "contains the entire Puppy filesystem, everything from '/' down"; made some other language more concise and (I hope) more comprehensible; and substituted "Do you want to continue?" [YES/NO] for "Click OK button to continue (or close window to quit)".

In "repup02.gif," the warning about using a lot of memory is based on my experience with Remaster Express (RemaX), which I wrote for Puppy 4.2. (After Puppy 4.2.1, Remaster Express went out when Tcl and Gnocl, which it required, were re-dumped.) A few users complained that Remaster Express crashed because it was using too much memory. I found that this would also be true for the original remaster script, since the memory-hogging culprit was "mksquashfs," which both scripts invoked. I also substituted the actual (calculated) size of the ISO file for "an extra 100 - 200 MB space (whatever the size of the ISO file is going to be)."

In "repup03.gif," I substituted myself for Barry as the person to notify if users want to suggest more stuff to be automatically copied. (Somebody let me know if it turns out that Barry still really wants to be the one to be notified, but my best guess is he doesn't!) I also added "your favorite file manager" as what to use to examine /tmp/root and copy files to it.

In "repup04.gif," I added some more examples of additional content that users might want to put into the puppycdbuild directory before burning the CD or creating the ISO.

In "repup05.gif," I changed the former language, which seemed a bit strange and confusing to me, to some language that didn't. Same goes for "repup06.gif," where I also added what I thought was a nice ending touch: "Have fun with Puppy, the personal computer user's best friend!"

If you want to test the script and verify that, yes, it does still work the same as before, just untar it, put "remasterpup3" in /usr/sbin along with remasterpup2, run /usr/sbin/remasterpup3 from the command line, and (if you're satisfied) change your Setup --> Remaster Puppy live-CD menu item to point to remasterpup3 instead of remasterpup2. Any comments or questions, please let me know.

Two corrections

Posted: Fri 04 Jun 2010, 09:23
by shinobar
Great work.

There are 2 corrections:
  1. 'LANG=C' at line 49 should be moved to after I18N settings, say line 212-.
  2. at line 64, ''DISTRO_FILE_PREFIX was missing. It should be:

    Code: Select all

     PREFIX1CHAR="`echo -n "$DISTRO_FILE_PREFIX" | cut -c 1`"

Posted: Sat 05 Jun 2010, 18:20
by pa_mcclamrock
Thanks! I'm glad someone here is more detail-oriented than me. :D Changes made, new tarball uploaded--let me know if you find any more changes that need to be made.

Remaster Confusion

Posted: Sat 05 Jun 2010, 21:20
by tlchost
Will this script remaster and include the changes/additons I have made to /root and etc?

I think Barry's version did not, and one had to use Dougal's version ....but I am old and confused.

Thanks
Thom

Re: Remaster Confusion

Posted: Sat 05 Jun 2010, 22:18
by pa_mcclamrock
tlchost wrote:Will this script remaster and include the changes/additions I have made to /root and /etc?
Yes. When you get to those stages, the dialog box tells you to open your favorite file manager and copy whatever you want from /root to /tmp/root and from /etc to /tmp/etc. If you want to automate the identification of your add-ons, you can edit the /usr/sbin/remasterpup3 script yourself, using lines like these (starting around line 485 or so) as templates (the first one is for copying all files in a directory, the second for copying an individual file):

Code: Select all

# Copy all of my-applications/
cp -af /root/my-applications/* /tmp/root/my-applications/
[ . . . ]
# ROX desktop settings:
cp -af /root/Choices/ROX-Filer/PuppyPin /tmp/root/Choices/ROX-Filer/
Just make a backup copy of /usr/sbin/remasterpup3 first, so you can restore it in case the script won't work after you modify it!

Posted: Tue 03 Sep 2013, 04:12
by leotan
There's a little bug in remasterpup versions 2 & 3 that causes it to abort with an Xdialog usage error message whenever there is an ISO image mounted.

In particular, there's a botched regex in the handling of the VIRTUALCD variable. To fix it, replace where it says:

Code: Select all

	
sed -e 's/on[ ].*+//'	
with this:

Code: Select all

	
sed -e 's/on [ ]*//'	
(mind the blanks).