# How to install packages which are needed only for development

**URL:** <https://discourse.julialang.org/t/how-to-install-packages-which-are-needed-only-for-development/21815>\
**Category:** General Usage\
**Tags:** package-manager\
**Created:** [March 13, 2019, 12:22pm UTC](https://discourse.julialang.org/t/how-to-install-packages-which-are-needed-only-for-development/21815 "2019-03-13T12:22:13Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)\
**Post date:** [March 13, 2019, 12:49pm UTC](https://discourse.julialang.org/t/how-to-install-packages-which-are-needed-only-for-development/21815/2 "2019-03-13T12:49:38Z")

</div>

> [@ffevotte](#):
>
> On my system, I installed all those packages in the default (v1.1) environment. Is that the correct way of doing things?

It’s one way, I usually use that myself

> [@ffevotte](#):
>
> It appears to me that, when a package is activated, you get access to:

Yea, well, if those are in the `LOAD_PATH` (see below).

> [@ffevotte](#):
>
> is it possible to avoid by-hand editing of `Project.toml` ?

No.

> [@ffevotte](#):
>
> nother thing which is not clear to me: in which environment does `Pkg.test` install test-specific dependencies if they were missing?

It’s a temporary environment that is cleaned up when tests are done.

> [@ffevotte](#):
>
> I haven’t found any place in the documentation (neither of [modules](https://docs.julialang.org/en/v1/manual/modules/) nor of [Pkg](https://julialang.github.io/Pkg.jl/)) where these details are clearly documented.

Stacking of LOAD\_PATH is documenter here: [Environment Variables · The Julia Language](https://docs.julialang.org/en/v1.2-dev/manual/environment-variables/#JULIA_LOAD_PATH-1).

> [@ffevotte](#):
>
> **Question 1:** Is the above a good way of doing things ?

Sure, seems easiest.

> [@ffevotte](#):
>
> **Question 2:** How can I test this? I.e make sure I did not forget any tools in my list. I currently:
> 
> 1. move the whole `~/.julia` directory away;
> 2. try and install everything in an empty environment, then check that I can perform everything asked in the training session;
> 3. move my original `~/.julia` back.
> 
> Is there a better way of doing this?

Instead of moving things you can set `DEPOT_PATH` to some test-directory, e.g. by setting `JULIA_DEPOT_PATH`, see [Environment Variables · The Julia Language](https://docs.julialang.org/en/v1.2-dev/manual/environment-variables/#JULIA_DEPOT_PATH-1)

---

_[View the full topic](https://discourse.julialang.org/t/how-to-install-packages-which-are-needed-only-for-development/21815)._
