Hello,
I want to make Zotero Standalone fully portable. However, on start-up Zotero creates a profile folder C:\Documents and Settings\username\Application Data\Zotero\Zotero with the following content:
|profiles.ini
|||Profiles/
|||||f450im62.default/
||||||||[...]
|||||||||zotero/
Zotero\Profiles\f450im62.default\zotero is the actual folder which Zotero uses. I would like to store this profile in Data\profile.
How can I tell Zotero to create its profile folder in Data\profile and use this one as default?
I tried to use DirectoriesMove in my launcher.ini as follows without any success:
[DirectoriesMove]
%APPDATA%\Zotero=%PAL:DataDir%\profile
You can view the complete source code here: https://github.com/orschiro/PortableApps/tree/master/Zotero%20Standalone...
Have you tried passing it the -profile command line switch and pointing that to %PAL:DataDir%\profile
Sometimes, the impossible can become possible, if you're awesome!
Your [DirectoriesMove] doesn't work because you've got it backwards.
You would need
profile=%APPDATA%\Zotero\profile
to have a directory called profile in Data moved to App\Zotero\profile on startup.But as John says, use the command line switch. If an app provides a way to redirect profiles/settings/etc you should always try to do it that way instead of manually making the launcher do it.
Thanks for the hint with the -profile option.
I created a bat file which launches Zotero as follows and which is working great:
START zotero.exe -profile "..\..\Data\profile"
Don't use a batch file, it isn't supported.
Use CommandLineArguments in your launcher.ini instead.
Thanks! I did not know about this option. Very clean solution.
Your developed code in the section [DirectoriesMove] is invalid due to the usage of the environment variable %APPDATA%. The "%APPDATA%\Zotero" is the location of the source directory, relative to the portable data directory (AppNamePortable\Data). The "%PAL:DataDir%\profile" includes the directory you want it to go to, so %PAL:DataDir%\%APPDATA%\Zotero\*.* gets copied to %PAL:DataDir%\profile\*.*.
But what is now the exact meaning of "%PAL:DataDir%\%APPDATA%\Zotero\*.*"? It leads to the following concrete path:
This path contains 2 drive letters (X and C), which leads to a failure.
Instead you should use the following code: