CondaPkg.jl icon indicating copy to clipboard operation
CondaPkg.jl copied to clipboard

Make it easier to add or remove multiple packages w/ Vector{String}

Open mkitti opened this issue 1 year ago • 1 comments

Currently one cannot add or remove packages as indicated by a Vector{String} see #134

This pull request allows for the following syntax.

CondaPkg.add(["numpy", "scipy", "matplotlib", "h5py"])
CondaPkg.rm(["numpy", "scipy", "matplotlib", "h5py"])

It implements this by creating a function _to_spec with two methods. For an existing *Spec, it just returns the spec. For an AbstractString, it returns a PkgSpec.

mkitti avatar Jul 04 '24 00:07 mkitti

@mkitti Thanks! Looks good. However the tests are failing on Windows for some mysterious reason that seems irrelevant to this PR (#137), I'm assuming it's a bug in micromamba. Can you replace the 4 packages in the test with jsonlines and cowpy since these are smaller and faster to install and aren't numpy please? This should make the tests pass.

cjdoris avatar Jul 07 '24 20:07 cjdoris

Thanks 🙂

cjdoris avatar Jul 11 '24 08:07 cjdoris