How do I install dependencies from the `[extras]` block of Project.toml to the project-wide manifest?

Many projects have a Project.toml that lists test dependencies in the [extras] block, following by a

test = [...]

block. This way, you can run julia --project in the base project directory and then ]test will automatically pull in all those dependencies.

However, for development purposes, I want to install the extra packages into the base project directory, without actually modifying Project.toml to change them into hard dependencies. Is there a way to do ]instantiate that also includes the extras? E.g. ]instantiate extras?

I think what you’re looking for is GitHub - JuliaTesting/TestEnv.jl: Activate your test enviroment, so you can use your test dependencies in the REPL

1 Like

But then I need to add TestEnv to the dependencies… or do you just install this to your global Julia env?

Install it in the global env, and use it with each of your packages