Request: portable settings storing
Original Reporter info from Mantis: Fr0sT
-
Reporter name:
Original Reporter info from Mantis: Fr0sT
- Reporter name:
Description:
Would be nice to have an option to make Lazarus portable (i.e. keeping settings inside its own folder). I know about cmd line option and issue #14804 but that's not enough. For example, currently you couldn't have portable Lazarus and launch associated file in it (associations do not include cmd line option).
So I suggest something like adding conditional define "portable" and having this code in the procedure InternalInit of <lazarus>\ide\include\<OS>\lazbaseconf.inc:
{$ifndef ver2_2_0}
{$ifdef portable}
PrimaryConfigPath := AppendPathDelim(ProgramDirectory) + 'profile';
{$else}
// the last part of the path returned by GetAppConfigDir is the application
// name. Replace that by 'lazarus', to make sure that lazbuild uses
// the same primary config path
PrimaryConfigPath:= ExtractFilePath(ChompPathDelim(SysToUTF8(GetAppConfigDir(False)))) + 'lazarus';
{$endif}
{$else}
// fpc 2.2.0 cannot handle spaces in path in some circumstances
PrimaryConfigPath:=ChompPathDelim(ProgramDirectory);
{$endif}
Also including this option into "Rebuild IDE" dialog would be awesome.
Mantis conversion info:
- Mantis ID: 19892
- Version: 0.9.30.1 (SVN)
- Monitored by: » Fr0sT (Fr0sT)