Reduce duplicated code and expose a function for getting the enonic home dir
This fixes #570
So if I wanted to make sure the directory was possible to override, I would first consolidate all different places the path to $HOME/.enonic was found.
Here is a first attempt to do that. Plus some actual tests for this repo
Hi @eiriksm !
Thank you for the effort !
Would you be interested to extend your PR with actual override mechanic as you see it ?
NB. Overriding the default folder might get a bit tricky in case of running in snapcraft where we create a symlink to .enonic folder because of their execution policy.
Sure
Here is the updated logic, including a test
No idea how to build the docs, but attempted to add it there. Updated the var name, and made it a const
Thanks ! Looks good ! Docs are built by github in master so we'll wait with merging until release !