# "using" with a local package?

**URL:** <https://discourse.julialang.org/t/using-with-a-local-package/101625>\
**Category:** New to Julia\
**Created:** [July 14, 2023, 1:22pm UTC](https://discourse.julialang.org/t/using-with-a-local-package/101625 "2023-07-14T13:22:58Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![frylock](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/frylock/32/50213_2.png) [@frylock](https://discourse.julialang.org/u/frylock)\
**Post date:** [July 14, 2023, 1:22pm UTC](https://discourse.julialang.org/t/using-with-a-local-package/101625/1 "2023-07-14T13:22:58Z")

</div>

I have a package (here let’s say “NEAT.jl”). It is company internal, and will never be shared. I started it with `] generate NEAT` (I am aware of [PkgTemplates](https://github.com/JuliaCI/PkgTemplates.jl), but it seemed that assumed that you were going to have a git repo set up, and that has other issues for me right now - sort of mentioned below).

In another package (also set up with `generate`) I want to bring in the functionality with `using` or some similar statement, but:

```julia
(@v1.9) pkg> activate --temp
  Activating new project at `/tmp/jl_2zw782`

(jl_2zw782) pkg> add /home/frylock/models/src/Wrappers/NEAT/Julia/NEAT/
ERROR: Did not find a git repository at `/home/frylock/models/src/Wrappers/NEAT/Julia/NEAT/`, perhaps you meant `Pkg.develop`?

```

Ordinarily, I’d just create a git repo to hush the error, but the way that we currently check things in is in _one gigantic repo containing everyone’s work_ (I know, not a good idea, but I’m going to have to lobby to fix that at a somewhat later date).

The way the software is deployed is that it is set up in a Docker container - on a server with no access to the public internet. On deployment, a script scrapes together all of the needed pieces and the Docker container is spun up for the engineer to use (later in development, we are supposed to do something different).

I have followed some of the other discussions here about local packages [like this one](https://discourse.julialang.org/t/workflow-for-local-packages-with-local-dependencies/30636/2), but I’m not yet very competent with making packages with Julia.

**Is `] dev` the right answer?**

---

<div class="post-metadata">

**Author:** ![ffevotte](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ffevotte/32/6587_2.png) [@ffevotte](https://discourse.julialang.org/u/ffevotte)\
**Post date:** [July 14, 2023, 1:49pm UTC](https://discourse.julialang.org/t/using-with-a-local-package/101625/2 "2023-07-14T13:49:50Z")

</div>

> [@frylock](#):
>
> Is `] dev` the right answer?

I’m not sure I completely understand your workflow, but it seems so, yes.

  

Another way would be to set up a local registry in your company, register `NEAT` in it and then add it as needed in other environments via

```julia
add NEAT

```

like any other registered package. But this is more infrastructure, and you’d also need to properly version and release your `NEAT` library for this to work well.

---

<div class="post-metadata">

**Author:** ![frylock](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/frylock/32/50213_2.png) [@frylock](https://discourse.julialang.org/u/frylock)\
**Post date:** [July 14, 2023, 1:52pm UTC](https://discourse.julialang.org/t/using-with-a-local-package/101625/3 "2023-07-14T13:52:57Z")

</div>

Thanks, and to be honest, I’m not sure that _I_ understand my workflow! 🤪
