Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

load .Winston.ini from home directory #239

Open
esheldon opened this issue Sep 11, 2015 · 1 comment
Open

load .Winston.ini from home directory #239

esheldon opened this issue Sep 11, 2015 · 1 comment

Comments

@esheldon
Copy link

Currently only the site-wide config, that in the CWD, and things in LOAD_PATH are looked for. It would be nice to look for a "dot" file in the home directory as well.

I would submit a pull request but I have not yet grokked how to develop Pkgs in julia

@mvkma
Copy link
Collaborator

mvkma commented Oct 16, 2015

I think this would be easily possible by adding homedir() here, maybe like so:

for dir in ["."; homedir(); Pkg.dir(); LOAD_PATH]
    fn = joinpath(dir, "Winston.ini")
    if isfile(fn) break end
    fn = joinpath(dir, "Winston", "src", "Winston.ini")
    if isfile(fn) break end
end

I'm not sure about the order though. I guess the file in the home directory should take precedence over the one shipped with the package and the site wide one, but what about the one in CWD?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants