# Invoking dune without parameters

**URL:** <https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222>\
**Category:** Community\
**Created:** [January 23, 2019, 5:50am UTC](https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222 "2019-01-23T05:50:51Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![UnixJunkie](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/unixjunkie/32/638_2.png) [@UnixJunkie](https://discuss.ocaml.org/u/UnixJunkie)\
**Post date:** [January 23, 2019, 5:50am UTC](https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222/1 "2019-01-23T05:50:51Z")

</div>

```auto
dune

```

is an alias for

```auto
man dune

```

I think an alias for

```auto
dune build

```

would have been a better choice.

---

<div class="post-metadata">

**Author:** ![LudwigPacifici](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/ludwigpacifici/32/1246_2.png) [@LudwigPacifici](https://discuss.ocaml.org/u/LudwigPacifici)\
**Post date:** [January 23, 2019, 6:22am UTC](https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222/2 "2019-01-23T06:22:56Z")

</div>

It depends of your point of view. What you describe looks like `make` behavior. In the Rust world, `cargo` (the equivalent of dune?) shows the help.

By default, showing the help is beginner friendly. On the other hand, doing an action, like start a build, would target experienced users.

Also `dune build` creates files. Running `dune` (aliased to a build) in a wrong directory would pollute it. More explicit typing, `dune build`, makes it less likely to happen. This not an issue if dune defaults to the help.

Why do you think it would be a better choice?

---

<div class="post-metadata">

**Author:** ![RogerT](https://avatars.discourse-cdn.com/v4/letter/r/5f8ce5/32.png) [@RogerT](https://discuss.ocaml.org/u/RogerT)\
**Post date:** [January 23, 2019, 7:56am UTC](https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222/3 "2019-01-23T07:56:08Z")

</div>

`dune --help` is quite universal, isn’t it?  
I feel that `dune` as an alias of `man dune` is confusing, as many shortcuts are.

---

<div class="post-metadata">

**Author:** ![UnixJunkie](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/unixjunkie/32/638_2.png) [@UnixJunkie](https://discuss.ocaml.org/u/UnixJunkie)\
**Post date:** [January 24, 2019, 1:18am UTC](https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222/4 "2019-01-24T01:18:32Z")

</div>

> Why do you think it would be a better choice?

It would save me typing ‘build’  
and hence make me more efficient.  
And, also default to what make does, which existed way before  
any Rust-related thingy.

PS: I guess I qualify as an experienced user of computers

---

<div class="post-metadata">

**Author:** ![c-cube](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/c-cube/32/1727_2.png) [@c-cube](https://discuss.ocaml.org/u/c-cube)\
**Post date:** [January 24, 2019, 4:29am UTC](https://discuss.ocaml.org/t/invoking-dune-without-parameters/3222/5 "2019-01-24T04:29:16Z")

</div>

You can also write a very small and simple makefile that invokes `dune` with the right options. I do that (also for rust’s cargo) and it works great. Also it makes it possible to choose whether the default behavior is “build” or “build + run test”.
