Multiple JULIA_PKGDIR directories in a hierarchy for supporting a shared environment

117 views
Skip to first unread message

David Parks

unread,
Jun 27, 2016, 1:28:25 PM6/27/16
to julia-users
I want to set up a specific Julia environment on a cluster for other people to use. I have particular packages, including some that are dev branches, and even some that draw from my own fork of a branch to support a custom feature for this environment. So the package setup is non trivial and I don't want everyone else to have to follow the details.

Is there a way (now or in the future) to have a hierarchy of package directories, so I could have a main repository that I setup and control for the relevant packages, but still allow users to extend on that but into their own package directory?

Or is there a way good way for me to auto-configure a complex package directory for the user? I suppose the obvious answer is to just write a package setup script, which might be a suitable solution. But I wonder if anything else is possible or on the horizon.

Thanks,
David

Stefan Karpinski

unread,
Jun 27, 2016, 2:03:13 PM6/27/16
to Julia Users
You can use LOAD_PATH to look in a stack of directories, and you can even set ENV["JULIA_PKGDIR"] to change which one Pkg manages, but you cannot manage more than one of them at the same time, since it's unclear what this would even do.

Tom Breloff

unread,
Jun 27, 2016, 2:24:27 PM6/27/16
to julia-users
Well presumably it could do something that the import logic already does, but I appreciate that it is complex logic.

David: @wildart is the person to follow for the future of package management.

Eric Forgy

unread,
Jun 27, 2016, 10:42:52 PM6/27/16
to julia-users
Hi David,

I'm not a pro, but I had similar issues and went with a main Julia package that contains many other Julia packages as Git submodules. In this way, my team can just clone the main Julia package and do a "git submodule init" and "git submodule update" and they get all the packages from the main Julia package. Then I added two lines to my .juliarc.jl file that add the Git submodule directory to my LOAD_PATH. Now my team can add any packages they like but are assured to have the same packages (and versions) for the main Julia package.

Best regards,
Eric
Reply all
Reply to author
Forward
0 new messages