# Project nested environments

**URL:** <https://discourse.julialang.org/t/project-nested-environments/72499>\
**Category:** General Usage\
**Tags:** question, package, environment\
**Created:** [December 3, 2021, 1:51am UTC](https://discourse.julialang.org/t/project-nested-environments/72499 "2021-12-03T01:51:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jekyllstein](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jekyllstein/32/4157_2.png) [@jekyllstein](https://discourse.julialang.org/u/jekyllstein)\
**Post date:** [December 3, 2021, 1:51am UTC](https://discourse.julialang.org/t/project-nested-environments/72499/1 "2021-12-03T01:51:32Z")

</div>

I have a package with an examples folder inside of it. I want the examples folder to have its own Project.toml with things like Plots that I don’t want as dependencies in the package itself. I created an environment in the examples folder but how do I add to the examples environment the main package itself?  
I.e. the directory would look like this

```julia
\SamplePackage\src\SamplePackage.jl 
\SamplePackage\Project.toml
\SamplePackage\examples\examplescript.jl 
\SamplePackage\examples\Project.toml

```

And then inside `examplescript.jl` I wanna use the package like this.

```julia
using SamplePackage 
using Plots 

#script code...

```

Where Plots isn’t part of the SamplePackage environment

---

<div class="post-metadata">

**Author:** ![Brad\_Carman](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/brad_carman/32/17631_2.png) [@Brad\_Carman](https://discourse.julialang.org/u/Brad_Carman)\
**Post date:** [December 3, 2021, 2:11am UTC](https://discourse.julialang.org/t/project-nested-environments/72499/2 "2021-12-03T02:11:01Z")

</div>

In the **examples** environment, simply run

(examples) pkg\>develop .

Here “.” would be the path to **SamplePackage** folder assuming you started Julia in that folder.

---

<div class="post-metadata">

**Author:** ![jekyllstein](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jekyllstein/32/4157_2.png) [@jekyllstein](https://discourse.julialang.org/u/jekyllstein)\
**Post date:** [December 3, 2021, 7:43am UTC](https://discourse.julialang.org/t/project-nested-environments/72499/3 "2021-12-03T07:43:52Z")

</div>

Thanks so much. I did that and it worked perfectly. Just has the reference to the directory above it. Didn’t realize I had to use “develop” instead of “add”
