CC: | adamk [...] cpan.org, kmx [...] cpan.org |
Subject: | Configuring portable perl (for a "semi-portable" installation) |
After "installing" a portable perl installation onto a PC (i.e., by using `scoop` [https://github.com/lukesampson/scoop]), I'd like to customize the install to access my home path using the usually recommended File::HomePath methods.
`scoop` installs the portable perl package in a directory under my home directory (%LOCALAPPDATA%) and sets up the PATH to make perl accessible. It does this to avoid requiring any elevated security levels for installation. So, it's really a regular installation into an unusual path. Parenthetically, I'm not sure that installation of the usual perl onto that path wouldn't work just as well, but I'm not privvy to the thoughts behind their choice of "portable perl".
Given this type of "semi-portable" installation, I'd like to be able to configure portable.perl to access the usual directories (~ aka %USERPROFILE%, etc.). To accomplish just the %USERPROFILE% access, I could make "<PERL_ROOT_PATH>/data" a symbolic link to "%USERPROFILE%", but that seems hackish.
Alternatively, the most straight forward method seems to me to be modifying the configuration in the `portable.perl` file. But, currently, HomePath:my_home path is just tacked onto <PERL_ROOT_PATH> no matter whether it's a relative or absolute path. So, that won't work. However, the code within "Portable" could be modified to use absolute directories when specified (which I'm happy to do, and, if you have a repo somewhere, then send you a pull request).
As I don't fully grok the larger design picture of "Portable", I'm not sure of the ramifications of making such a change. But, I think it might be nice to move toward having a fully relocatable perl installation which can still access all of the host resources like a normal perl installation (hence, "semi-portable").
If this all seems like a wrong-headed direction or non-productive for you, I can start expermenting with using a full perl installation placed solely within the USER directory tree. If that works, I can set up my own bucket for scoop and/or discuss changing the copy that `scoop` installs with it's creator.
Do you have any input on this?
Thanks for your attention.