NOTE: Before running this example, you must first put a copy of the JPEPortable.exe in the Special directory and rename it to notepad.exe.
This example presents the way to use a fixed path within a [SpecialFolders] section's path specification for a special folder. It does this by setting up the current user desktop and the current user my documents directories as fake drive J: encrypted directories, while keeping the rest of the portable file system as usual.
If the J: drive letter is already in use on your system, you will need to change this drive letter in the ini if you would like to run this example and see the plugin in action.
The Launch section
This section's settings are read by the JPE-built app launcher and each overrides its equivalent stored within the launcher executable file.
[Launch]
Path=%System%\%appname%.exe
JPERuntime=..\Runtime\Def\jauntePE.dll
JPERuntimeIni=.\%appname%_jauntePE.ini
ExeDir=0
The rest of this file's sections are all JPE runtime ini sections and are read by the JPE runtime dll and again, used to override equivalent settings stored within the launcher executable file.
The Redirection section
Nothing new here.
[Redirection]
MemRegistry=2
UseIcon=1
ModFrame=1
ExcludeAppDir=1
The Registry sections
With registry redirection, by default ALL registry changes are redirected, so we need to exclude everything (the 1=* line) and then include back in only those needing redirection. In this example we're not concerned with capturing any changes other than those that the application itself makes.
[Registry]
Use=1
Data=..\Data\%appname%.reg
[RegistryExclude]
1=*
[RegistryInclude]
1=HKEY_CURRENT_USER\Software\Microsoft\%appname%
The Filesystem sections
As with registry redirection, by default ALL file system changes are redirected, so we need to exclude everything (the 1=* line) and then include back in only those needing redirection.
In this example we're only interested in portablizing the current user's "My Documents" shell folder (as this is a good example of how to carry around your docs and still be able to get to them quickly) and the fonts folder (to show you how to make use of "portable" fonts.) Changes to all other folders, such as the desktop or any of the "All Users" folders, will not be redirected.
Also note that you will only see the redirected "My Documents" contents while using the File->Open shell browser window.
[Filesystem]
Use=1
Data=..\Data\Filesystem
[FilesystemExclude]
1=*
[FilesystemInclude]
1=5
3=16
3=20
[SpecialFolders]
5=J:\User\Documents
16=J:\User\Desktop
20=Fonts
The CryptoDrive sections
These sections set up the Filesystem directory as the base for this example's fake J: drive, which is encrypted.
[CryptoDrive]
Use=1
Path=.\Filesystem
[CryptoDriveJ]
DriveType=2
CryptType=3
Serial#=123456789
Password=This is a passphrase
Volume=jpeDriveJ
Path=.\