I wanna change the temp folder to a directory on my D drive yet when I restart the program it has reverted to using C drive User/appdata. How do I fix this? I tried changing it in the settings and config files and made them readonly then the program wouldn't start. Please help
To change that handling, you can edit the
AudacityPortable.ini
(located in the folder
[your PortableApps-Directory]\AudacityPortable\App\AppInfo\Launcher\
).Look for:
Change
Value=
to the directory on your D drive (that would kind of hard code it and revert any changes you make in audacity itself).Or simply comment that section out. Should look like that:
That would remove the PA.c Launcher's handling of the temp folder, keep that in mind, if you copy your AudacityPortable Folder to a pendrive to use it portably.
(I'm not completly shure, if the Launcher handles the step in
FileWrite1
toFileWrite3
genrously, if you comment that section out. Maybe you have to adapt the remainingFileWriteNs
)-edit-
Maybe there's a simpler, but more radical solution: If It's not just AudacityPortable, but all other Application you use, you can simply change the systemwide TEMP settings ([WIN-KEY]+[Break] -> Advanced System Settings -> Advanced -> Enviroment Variables...).
Be careful not to assign a nonexistend directory (e.g. removable drive that is not present the whole time).
If a FileWrite section gets commented out, it is necessary to re-number the remaining sections.
Thanks for clarification.
(Actually, I was too lazy to check that myself... )
I use portable apps cause I don't want things written to my registry, so using it with a pendrive doesn't apply to me. Thanks
Thinkpad,
I don't use Audacity but I do see what your problem is with Audacity and files written into the system TEMP and TMP folders. Years ago I had the same kind of issue with Firefox Portable still writing some files into locations in the system TEMP folder. Then I found this thread on mozillaZine forums: [SOLVED] Force Folder "mozilla-temp-files" to a Ramdisk?
If you have a spare half-hour it might be worth your while to read through that thread and pay particular attention to what is being said about launching programs via a batch file where the batch file sets the location of the TEMP and TMP directories for the particular program being launched via the batch file. Nowadays I use that information for several programs, portable and non-portable on system, to force them to write their temp files into a ramdisk. Beauty of it is that the re-direction is only in force for the program that is launched by the batch file - though the redirection also applies to any child process that the program might also launch.
So, let's say for Firefox Portable, I use the following batch code to force Firefox to write TEMP/TMP files into the ramdisk location:
REM Create the folders you want temp files to be written into. If the
REM folders already exist it won't be a problem for the batch file.
mkdir W:\TEMP
mkdir W:\TMP
REM Now set the system paths to use those locations for temp files.
set TEMP=W:\TEMP
set TMP=W:\TMP
REM The above paths will now be used for temp files for the program below
REM (and any child process it also launches). Those paths only apply to that program,
REM and its child processes, launched by the batch. Those are not paths applied
REM system-wide.
start "" "E:\PORTABLES\Firefox [PortApps]\FirefoxPortable.exe"
exit
So once I have the batch file constructed I just make a shortcut to the batch file and always launch Firefox Portable via that shortcut (which launches the batch file, which then runs the code). Note that I am launching the proper Firefox Portable launcher file - i.e. "FirefoxPortable.exe" - the "firefox.exe" that the portable launcher then launches gets the location of the TEMP/TMP folders passed to it by the system because it is considered a child process of the ""FirefoxPortable.exe" launcher. (Hope that makes sense.)
Test that with Audacity and see if it works for you. Just adjust the paths to suit your own system and the program you want to launch. And remember to always have the batch launch the appropriate PortableApps launcher exe file - never launch the program's proper exe file directly yourself.
Use Portable Apps on both Flash Drive and HDD/SSD.