bjorkintosh has quit [Remote host closed the connection]
oriba has joined #ocaml
mxns has joined #ocaml
zebrag has quit [Quit: Konversation terminated!]
zebrag has joined #ocaml
mxns has quit [Ping timeout: 240 seconds]
borne has quit [Ping timeout: 245 seconds]
<d_bot>
<rgrinberg> I rely on special features like including sub modules in the tarball. Don’t think opam publish offers this
Serpent7776 has quit [Read error: Connection reset by peer]
mxns has joined #ocaml
mxns has quit [Ping timeout: 260 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
Haudegen has quit [Quit: No Ping reply in 180 seconds.]
Haudegen has joined #ocaml
mxns has joined #ocaml
noonien has joined #ocaml
olle has quit [Ping timeout: 240 seconds]
elusive has quit [Quit: Leaving]
mxns has quit [Ping timeout: 246 seconds]
<d_bot>
<colin> How are you meant to generate documentation with `odoc`? I've tried several times and nothing happens. I thought it'd be the case that if you have some library in a folder with a `dune` file then running `dune build @doc` would produce documentation but it does nothing.
<d_bot>
<colin>
<d_bot>
<colin> Failing that, how do you make `ocamldoc` aware of libraries? It seems to mostly work except in cases where modules from libraries are being referenced.
vicfred has joined #ocaml
<d_bot>
<mnxn> I believe the documentation is built to `_build/default/_doc`
<d_bot>
<colin> I thought the same thing but everything online just says: "run `dune build @doc`". I do that and nothing happens each time.
<d_bot>
<mnxn> Did you check that directory? If it's doing nothing, it's probably already built.
<d_bot>
<colin> Yeah, nothing. Perhaps I just misunderstand how you're meant to structure OCaml projects.
<d_bot>
<mnxn> The `_build` folder is relative to the directory with the `dune-project` file
<d_bot>
<colin> I don't want to post code here but is there any online example of a small library project, using `dune`, that will build documentation when built with `dune build @doc`?
<d_bot>
<colin> Everywhere online just says the same "run `dune build @doc`" but that just doesn't work. Are you meant to have a bunch of other stuff that isn't mentioned? Do I need `.opam` files?
mxns has joined #ocaml
<d_bot>
<mnxn> Do you have a `package` field in `dune-project`? It seems that's neccessary.
<d_bot>
<colin> apparently adding that means I then need to add .opam files
<d_bot>
<mnxn> You don't
<d_bot>
<mnxn> opam files will only be created if you have `generate_opam_files` in `dune-project`
<d_bot>
<mnxn> You can also do `dune build @doc-private` to get documentation for libraries that are not in a package
<d_bot>
<colin> I've added a package name corresponding to a folder containing code for a library (with its own `dune` file). It has generated documentation with nothing in it. Do I need to write `.mli` files or something?
<d_bot>
<mnxn> I guess so
<d_bot>
<mnxn> It's good practice anyways
curtosis has joined #ocaml
curtosis is now known as curtosis[away]
<d_bot>
<colin> alright so now it's generating docs with broken links
<d_bot>
<mnxn> How so?
<d_bot>
<mnxn> Actually I don't think an `.mli` file is neccessary
<d_bot>
<mnxn> You just need `public_name` in the dune file
<d_bot>
<colin> Then you need `.opam` files apparently.
<d_bot>
<colin> I wish this documentation stuff was more hacky.
<d_bot>
<mnxn> No?
<d_bot>
<mnxn> dune doesn't say anything about opam files
<d_bot>
<colin> adding `(public_name xyz)` to the `dune` file for a library says that I must add a `xyz.opam` file at the root of my project
<d_bot>
<mnxn> What version of dune are you using?
<d_bot>
<mnxn> I don't get that on version 2.8.4
<d_bot>
<colin> `2.7.1`
<d_bot>
<froyo> i get that too
<d_bot>
<froyo> for generate_opam_files to work, you need an empty stub
<d_bot>
<froyo> at least that is
<d_bot>
<colin> sigh, as nice as odoc seems, it just seems like it only works if you have things configured in a specific way
<d_bot>
<froyo> also hi colin
<d_bot>
<colin> I yearn for a hacky tool that just does what I say and doesn't violate the DWIM (Do What I Mean) principle