These are some scripts I wrote to make it easier to work on specific files within an initrd.gz. I publish them here just in case they are useful to others.
initrd-extract.sh: extract a file from an initrd.gz, used by the following 2 scripts
extract-bootconfig: extract "BOOTCONFIG" from an initrd.gz
extract-init: extract "init" from and initrd.gz
initrd-replace.sh: replace a file in an initrd.gz, used by the following 2 scripts
store-bootconfig: replace "BOOTCONFIG" in an initrd.gz
store-init: replace "init" in an initrd.gz
gyro
scripts to extract and store files in initrd.gz
scripts to extract and store files in initrd.gz
- Attachments
-
- initrd-scripts.tar.gz
- In any directory, "tar xzf initrd-scripts.tar.gz" to extract the 6 files.
- (916 Bytes) Downloaded 649 times
These scripts are only useful for people modifying files that are contained within the file "initrd.gz".
No, the scripts cannot be used to add or remove applications.
I use them when modifying the "init" script that loads the various sfs files that are puppy. It means I can easily inject a different version of the "init" script into an "initrd.gz" file. This is the script that gets modified to add or remove support for boot parameters, or add support for ext3/ext4 pupsave files.
NOTE: To get some help on the parameters required by the scripts, just enter the name of the script file without any parameters.
gyro
No, the scripts cannot be used to add or remove applications.
I use them when modifying the "init" script that loads the various sfs files that are puppy. It means I can easily inject a different version of the "init" script into an "initrd.gz" file. This is the script that gets modified to add or remove support for boot parameters, or add support for ext3/ext4 pupsave files.
NOTE: To get some help on the parameters required by the scripts, just enter the name of the script file without any parameters.
gyro
- abushcrafter
- Posts: 1418
- Joined: Fri 30 Oct 2009, 16:57
- Location: England
- Contact:
- abushcrafter
- Posts: 1418
- Joined: Fri 30 Oct 2009, 16:57
- Location: England
- Contact:
I know. I was making the suggestion too the main puppy devs that might be reading this thread. Though I should mention this in there threads for that I guess...gyro wrote:The powers that be, are free to make use of my code in any way that they might find useful. But I have no control over what goes into "devx".abushcrafter wrote:Thanks. What about having these scripts in the "devx" SFS?
gryo
[url=http://www.adobe.com/flashplatform/]adobe flash is rubbish![/url]
My Quote:"Humans are stupid, though some are clever but stupid." http://www.dependent.de/media/audio/mp3/System_Syn_Heres_to_You.zip http://www.systemsyn.com/
My Quote:"Humans are stupid, though some are clever but stupid." http://www.dependent.de/media/audio/mp3/System_Syn_Heres_to_You.zip http://www.systemsyn.com/
now supporting DISTRO_SPECS
Added support for DISTRO_SPECS. and updated initrd-replace.sh so that the "bak" file is ".bak.gz" not ".gz.bak"
extract-distro-specs:
extract "DISTRO_SPECS" from an initrd.gz
store-distro-specs:
replace "DISTRO_SPECS" in an initrd.gz
extract-distro-specs:
extract "DISTRO_SPECS" from an initrd.gz
store-distro-specs:
replace "DISTRO_SPECS" in an initrd.gz
- Attachments
-
- initrd-scripts.tar.gz
- use "tar xzf /path/to/downloaded/initrd-scripts.tar.gz" in the directory where you want them to go.
- (1.04 KiB) Downloaded 623 times