How to use SemVer with Julia?

How can I add a package from a specific version to Julia, in my Project.toml looks like I only bind it to an specific commit

[deps]

Distributions = “31c24e10-a181-5473-b8eb-7969acd0382f”

JSON = “682c06a0-de6a-54ab-a142-c8b1cf79cde6”

Luxor = “ae8d54c2-7ccd-5906-9d76-62fc9837b5bc”

Pipe = “b98c9c47-44ae-5843-9183-064241ee97a0”

Plots = “91a5bcdd-55d7-5caf-9e0b-520d859cae80”

PyPlot = “d330b81b-6aea-500a-939a-2ce795aea3ee”

Those are not commits, they are UUIDs.

If you want to add compatibility constraints, see https://julialang.github.io/Pkg.jl/v1/compatibility/

If you want to install a specific version, use e.g.

pkg> add Example@0.5

See https://julialang.github.io/Pkg.jl/v1/repl/#repl-add

3 Likes