NOTE: Before running this example, you must first put a copy of the JPEPortable.exe in the RegEdit directory and rename it to fromSys.exe.

This example presents a simple way of using a portablized RegEdit to export the contents of one or more system registry keys to portable desktop .reg files for later import into an application's JauntePE portable registry.

The ini itself...


The Launch section

This section's settings are read by the JauntePE-built app launcher and each overrides its equivalent stored within the launcher executable file.

[Launch]
Path=%Windows%\regedit.exe
JPERuntime=..\..\Runtime\jauntePE\def\jauntePE.dll
JPERuntimeIni=.\fromSys_jauntePE.ini
ExeDir=0

The rest of this file's sections are all JauntePE runtime ini sections and are read by the JauntePE runtime dll and again, used to override equivalent settings stored within the launcher executable file.


The Redirection section

The only settings of note here are FillRegistry, RegMerge, and RegIgnDel.

FillRegistry is a new setting that is used to temporarily "fill in" the missing pieces of a portable registry's hierarchy. A registry browsing application such as RegEdit can then be run and the portable registry will be treated as if it were the system registry. MemRegistry must be on in order to use FillRegistry.

RegMerge is a new setting that is used to combine the portable registry's contents with the system registry's contents as seen by a registry browsing application. With both FillRegistry and RegMerge enabled, RegEdit browses the merged contents of the two registrys as if they were one, with the portable registry's contents taking precedence in cases where a given key exists in both the portable and system registrys.

RegIgnDel is a new setting that is used to tell the JauntePE runtime to treat deleted portable registry keys as if they don't exist in both the portable registry as well as the system registry, until they are re-added by the application to the portable registry. This allows for correct handling of the case where a key might exist in both the portable registry and the system registry. Normally when that key is deleted by an application, only the portable registry is affected; leaving the system registry key intact. But for applications that re-read the list of registry keys after a key deletion, the just-deleted portable key will be shown as still existing since it does exist in the system registry. RegIgnDel circumvents this problem by temporarily adding the just-deleted key onto the RegistryIgnore list, taking it off that list if and when it is re-added.

[Redirection]
UseIcon=1
ModFrame=1
MemRegistry=1
FillRegistry=1
RegMerge=1
RegIgnDel=1


The Registry sections

In this example the portable registry is only used to keep track of the RegEdit settings stored in the registry. So the name of the launcher is chosen as the name of the portable registry in order to avoid confusing it with the other example RegEdit portable registrys. Also note that, as in the editJPE example, the system registry settings for RegEdit are ignored.

Since this example is all about exporting system registry key entries for later importing into a JauntePE portable registry, there obviously shouldn't be any changes made to the registry other than the RegEdit settings changes that take place with normal use of RegEdit. So, the PortableRegExclude and ...Include sections are used to ensure that no inadvertent registry changes made are stored to the portable registry .reg file. As an added benefit, given this registry usage arrangement, this example presents an ideal way to safely use any registry editing/browsing application against the system registry as if it were in a "read only" mode.

[Registry]
Use=1
Data=.\fromSys.reg

[RegistryIgnore]
1=HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Applets\Regedit

[PortableRegExclude]
1=*

[PortableRegInclude]
1=HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Applets\Regedit


The Filesystem sections

The primary reason for this example is to portably export registry key entries from the system registry for later import into a JauntePE portable registry. So the portable file system must be used in order to provide a place for portable storage of the to-be-exported system .reg files. But only one storage location is needed. So the user desktop folder was chosen since it is RegEdit's default "export to" location.

[Filesystem]
Use=1
Data=..\Data

[FilesystemExclude]
1=*

[FilesystemInclude]
1=16

[SpecialFolders]
16=User\Desktop