# Package development of a not yet public package

**URL:** https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933
**Category:** General Usage
**Created:** [August 23, 2018, 12:06pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933 "2018-08-23T12:06:37Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)
#### Post date: [August 23, 2018, 12:06pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/1 "2018-08-23T12:06:37Z")

</div>

I am having a little trouble with package development. It seems, `Pkg3` prefers to do some caching here and there.

I hava a `MyPack.jl/` folder containing my package (with git repository `src/``docs/` `test/` and such)  
When I am in Atom (Juno) I do something like  
`>pkg develop .`  
which adds a relative path from the `.Julia/` folder in my home dir to said `MyPack.jl/`folder.

Then I can just run the tests (`include('test/runtests.jl')`or generate the documentation (that’s what I am working on at this moment) `include('docs/make.jl')`. Either way I might have a bug somewhere, let’s say even in an early stage at compile time, so this include errors…

On the old `0.6` (where I had the `MyPack.jl`in my PATH) I fix the bug and restarted Julia (maybe even that could get nicer) and would just `using MyPack`or reissue above test/make.

On `0.7` however with the above approach it quite often _keeps_ the bug I just fixed (and I am sure I saved the file and such).  
The one thing that does work is a `git commit`, but for every character that I fix and test a commit would really clutter my history.  
Neither `pkg> update .` nor `pkg> update MaPack` nor a new `pkg> develop .` solve this issue, also neither of them after restarting Julia.

So what’s the best workflow to develop a package with Julia 0.7/1.0 and `Pkg3` (with Atom on Mac OS for example)?

---

<div class="post-metadata">

### Author: ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)
#### Post date: [August 23, 2018, 12:26pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/2 "2018-08-23T12:26:02Z")

</div>

Could you show `status` output. It seems that you have done `add` and is tracking the repo instead of the actual files.

---

<div class="post-metadata">

### Author: ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)
#### Post date: [August 23, 2018, 12:39pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/3 "2018-08-23T12:39:56Z")

</div>

Actually that is exactly what I fear it does. So in any way I would be interested in how to do the one _and_ the other to learn the difference 🙂

```julia
(v0.7) pkg> status
    Status `~/.julia/environments/v0.7/Project.toml`
  [c52e3926] Atom v0.7.3
  [e30172f5] Documenter v0.19.6
  [e5e0dc1b] Juno v0.5.2
  [0fc0a36d] MyPack v0.0.0 [`~/.julia/environments/v0.7/../../../Repositories/Software/MyPack.jl`]
  [0796e94c] Tokenize v0.5.2
  [d6f4376e] Markdown
  [10745b16] Statistics

```

Also note the version number, since I did not yet get used to the `Project.toml` (for example looking up uuids for deps) and I am glad having gotten `REQUIRE` to work

---

<div class="post-metadata">

### Author: ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)
#### Post date: [August 23, 2018, 12:47pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/4 "2018-08-23T12:47:19Z")

</div>

That looks indeed like it is tracking by path. What does `Base.find_package("MyPack")` say?

---

<div class="post-metadata">

### Author: ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)
#### Post date: [August 23, 2018, 2:23pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/5 "2018-08-23T14:23:16Z")

</div>

Seems to be right:  
`"/Users/[...]/Repositories/Software/MyPack.jl/src/MyPack.jl"`– so maybe in one of the restarts I did the right thing to switch to not using the git repository but the folder.

---

<div class="post-metadata">

### Author: ![adamslc](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/adamslc/32/3452_2.png) [@adamslc](https://discourse.julialang.org/u/adamslc)
#### Post date: [August 23, 2018, 2:56pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/6 "2018-08-23T14:56:19Z")

</div>

> [@kellertuer](#):
>
> On the old `0.6` (where I had the `MyPack.jl` in my PATH) I fix the bug and restarted Julia (maybe even that could get nicer) and would just `using MyPack` or reissue above test/make.

Check out [Revise.jl](https://github.com/timholy/Revise.jl) if you want to reduce the number of times that you need to restart `julia`.

---

<div class="post-metadata">

### Author: ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)
#### Post date: [August 23, 2018, 3:08pm UTC](https://discourse.julialang.org/t/package-development-of-a-not-yet-public-package/13933/7 "2018-08-23T15:08:12Z")

</div>

That looks really neat. I am still missing (just a few) things that made writing code in Matlab nice (wile a lot other are already far better in Julia) – Revise seems to fix one dev-step for me 🙂 (just a few plot features to go then).
