Package Manager (0.7) - Difference between CLI add and Pkg.add

Hi, I am just starting to use 0.7, and I’m a bit confused as to how the new package manager for adding packages. Generally are we still supposed to be using Pkg.add, or should we now do everything via the new CLI (which you activate with the “]” key)?

I’ve added some packages via the CLI (using add PackageName#master) as I wasn’t able to checkout the master branches for packages via Pkg.checkout or Pkg.develop, and when “using” those packages, Julia is unable to find some of the dependencies (even though they are in the packages directory).

Thanks!

3 Likes

Is there somewhere in the Docs or on here that discusses this? I wasn’t able to find anything.

Pkg.add and ] add are two different interfaces to the same functionality.

The current docs are here: https://julialang.org/Pkg.jl/latest/

https://docs.julialang.org/en/latest/manual/code-loading/ is also good reading

1 Like

OK, maybe this is a bug of some sort then. I was using the command line add to add IndexedTables, and it can’t seem to find DataValues even though it is in the package directory:

ERROR: LoadError: LoadError: ArgumentError: Module DataValues not found in current path.
Run `Pkg.add("DataValues")` to install the DataValues package.

DataValues doesn’t exist in the REQUIRE file of IndexedTables. File a bug report with the package.

1 Like

ah thanks!!

The error message on master is considerably better and tells you as much.

2 Likes