Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate init subcommand to use cmdliner nested subcommand API #6169

Merged
merged 2 commits into from
Oct 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@
For instance `%{coq:version}` (#6049, @Alizter)

- update vendored copy of cmdliner to 1.1.1. This improves the built-in
documentation for command groups such as `dune ocaml`. (#6038, @emillon)
documentation for command groups such as `dune ocaml`. (#6038, @emillon,
#6169, @shonfeder)

- The test suite for Coq now requires Coq >= 8.16 due to changes in the
plugin loading mechanism upstream (which now uses findlib).
Expand Down
12 changes: 8 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@ developed at [Jane Street][js] and is now maintained by Jane Street,
community.

Contributions to Dune are welcome and should be submitted via GitHub
pull requests against the `main` branch. Dune is distributed under
the MIT license and contributors are required to sign their work in
order to certify that they have the right to submit it under this
license. See the following section for more details.
pull requests against the `main` branch. See [./doc/hacking.rst][hack]
for a guide to getting started on the code base.

Dune is distributed under the MIT license and contributors are
required to sign their work in order to certify that they have the
right to submit it under this license. See the following section for
more details.

Signing contributions
---------------------
Expand Down Expand Up @@ -71,6 +74,7 @@ your commit automatically with `git commit -s`.
[dco]: http://developercertificate.org/
[js]: https://www.janestreet.com/
[ocl]: http://ocamllabs.io/
[hack]: ./doc/hacking.rst

Coding style
------------
Expand Down
21 changes: 0 additions & 21 deletions bin/dune_init.ml
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,6 @@ module Dialect = Dune_engine.Dialect
syntax tree (CST) a good deal. *)
module Cst = Dune_lang.Cst

module Kind = struct
type t =
| Executable
| Library
| Project
| Test

let to_string = function
| Executable -> "executable"
| Library -> "library"
| Project -> "project"
| Test -> "test"

let commands =
[ ("executable", Executable)
; ("library", Library)
; ("project", Project)
; ("test", Test)
]
end

(** Abstractions around the kinds of files handled during initialization *)
module File = struct
type dune =
Expand Down
13 changes: 0 additions & 13 deletions bin/dune_init.mli
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,6 @@

open! Stdune

(** Supported kinds of components for initialization *)
module Kind : sig
type t =
| Executable
| Library
| Project
| Test

val to_string : t -> string

val commands : (string * t) list
end

(** The context in which the initialization is executed *)
module Init_context : sig
type t =
Expand Down
Loading