JULIA_PKGDIR and Julia-0.7

There are a few different ways and which one is best depends on your use case.

One way is to have your own registry. Pkg3 supports multiple simultaneous registries so by putting your own registry in .julia/registries (in addition to the default one) you can have your own set of packages, add and upgrade them exactly like the ones in the default registry. The tooling for setting up a registry is however lacking at the moment.

Another is to track git repositories using pkg> add localpath#branch where localpath is a path to a git repository. This works exactly like adding a repo at some branch from the internet. When commits are added to the branch, update will pull them in.

The third way is to track a directory, i.e. saying that julia should load the package from a certain path. This is done by doing dev localpath where localpath is a path to a package (doesn’t have to be a git repository). This simply tells julia that when loading the package, load it from that path. Any changes made to the files in that path is reflected when the package is reloaded.

4 Likes