# Organizing a project with a CLI

**URL:** https://discourse.julialang.org/t/organizing-a-project-with-a-cli/65005
**Category:** New to Julia
**Tags:** question, package, structure
**Created:** [July 20, 2021, 9:24pm UTC](https://discourse.julialang.org/t/organizing-a-project-with-a-cli/65005 "2021-07-20T21:24:24Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![orome](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/orome/32/26965_2.png) [@orome](https://discourse.julialang.org/u/orome)
#### Post date: [July 20, 2021, 9:24pm UTC](https://discourse.julialang.org/t/organizing-a-project-with-a-cli/65005/1 "2021-07-20T21:24:24Z")

</div>

I have a project that I’d like to add a CLI to (using [`Comonicon.jl`](https://comonicon.org/stable/project/#Setup-the-build.jl)) and I’m not sure how to organize the addition of the CLI. Ideally I’d like to

1. keep by base project, `MyPackage` on its own so people can just `add`/`using` `MyPackage` without also bothering with the CLI and its dependencies unless they want to, but
2. somehow distribute the CLI along with the package so that they can access it’s functionality at the command line with `my package <args>`.

I’m able to to pretty much exactly that in [Haskell](https://hackage.haskell.org/package/crypto-enigma) and [Python](https://pypi.org/project/crypto-enigma/), but am having trouble sorting out the right way to do it in Julia.

---

<div class="post-metadata">

### Author: ![Tero\_Frondelius](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tero_frondelius/32/7629_2.png) [@Tero\_Frondelius](https://discourse.julialang.org/u/Tero_Frondelius)
#### Post date: [July 21, 2021, 7:28am UTC](https://discourse.julialang.org/t/organizing-a-project-with-a-cli/65005/2 "2021-07-21T07:28:39Z")

</div>

Maybe you can find the answer from here: [Julia Python equivalent of \_\_main\_\_?](https://discourse.julialang.org/t/julia-python-equivalent-of-main/35433)

---

<div class="post-metadata">

### Author: ![orome](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/orome/32/26965_2.png) [@orome](https://discourse.julialang.org/u/orome)
#### Post date: [July 21, 2021, 5:09pm UTC](https://discourse.julialang.org/t/organizing-a-project-with-a-cli/65005/3 "2021-07-21T17:09:07Z")

</div>

That’s helpful but my question was more about the idiom for project organization and specifying dependencies.
