-
-
Notifications
You must be signed in to change notification settings - Fork 60
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
Provide an example of a Dune file in OCaml syntax #294
Comments
@nobrowser, @anuragsoni, @Risto-Stevcev: I just changed the README instructions for Dune; they now recommend using Dune's OCaml syntax: (* -*- tuareg -*- *)
let preprocess =
match Sys.getenv "BISECT_ENABLE" with
| "yes" -> "(preprocess (pps bisect_ppx))"
| _ | exception _ -> ""
let () = Jbuild_plugin.V1.send @@ {|
(library
(public_name my_lib)
|} ^ preprocess ^ {|)
|} I changed the starter repo accordingly, as a minimal example, and there is also a tidy patch showing the difference to Doing it this way seems to work pretty well:
We've already been using this in odoc for a while (I had forgotten). The odoc version is slightly less tidy :) I also just switched to Lwt to doing this (back, actually, we did this also in Lwt at some point in 2017 or so): ocsigen/lwt@7baf8b9 |
@aantron I figured out that since I'm writing a cross-compat library for bs + native, I don't actually need to have it run for native since I'm ensuring code coverage on the bs side. I just add it as a |
I'll keep this in mind for the future, for when there is a version of Dune that can offer a better Bisect integration on the native side. |
...which works around Dune not supporting a development-only PPX, ocaml/dune#57.
The text was updated successfully, but these errors were encountered: