Giter Site home page Giter Site logo

odoc2docset's Introduction

odoc2docset

Converts Odoc generated documentation into Dash (or Zeal) docsets.

Installation

opam pin add odoc2docset https://github.com/jfeser/odoc2docset.git
opam install odoc2docset

Usage

To generate documentation for all installed packages, run:

odoc2docset Opam.docset

To generate documentation for a subset of packages, run:

odoc2docset Opam.docset pkgA pkgB pkgC

Compression

By default, odoc2docset will create uncompressed docsets. Compressed docsets can be created using the --compress option. This mode requires tarix and GNU tar.

Known bugs

Running this tool to update an existing docset while Dash is running can fail, because the Sqlite database does not support concurrent accesses. If the tool crashes with a Sqlite BUSY exception, quit Dash and try again.

odoc2docset's People

Contributors

jfeser avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

odoc2docset's Issues

Not installable - dependencies underspecified?

Hi there. Thanks for creating this. I'm trying to install it and it seems like the dependencies are maybe underspecified in the dune/opam files.

Trying to install in a fresh 4.12.0 OPAM switch errors out, talking about the shell library not being found, but there may be more.

[ERROR] The compilation of odoc2docset failed at
        "/Users/holmdunc/.opam/opam-init/hooks/sandbox.sh build dune build -p
        odoc2docset -j 11 @install".

#=== ERROR while compiling odoc2docset.~dev ===================================#
# context     2.0.8 | macos/x86_64 | ocaml-base-compiler.4.12.0 | pinned(git+https://github.com/jfeser/odoc2docset.git#b490f684)
# path        ~/.opam/xyz/.opam-switch/build/odoc2docset.~dev
# command     ~/.opam/opam-init/hooks/sandbox.sh build dune build -p odoc2docset -j 11 @install
# exit-code   1
# env-file    ~/.opam/log/odoc2docset-74833-21fead.env
# output-file ~/.opam/log/odoc2docset-74833-21fead.out
### output ###
# File "bin/dune", line 5, characters 51-56:
# 5 |             logs.cli fmt.cli fmt.tty core cmdliner shell)
#                                                        ^^^^^
# Error: Library "shell" not found.
# Hint: try:
#   dune external-lib-deps --missing -p odoc2docset -j 11 @install

Build error, unbound module Model

Running on a fresh archlinux, attempts to build — either via pinning via opam and letting it work its magic, or directly via dune — fail with

File "bin/main.ml", line 46, characters 11-21:
Error: Unbound module Model

I tried switching to earlier compiler versions, tried installing the exact versions of the packages mentioned in odoc2docset, assuming that something had provided Model, but is providing it no more — without success.

Which package is the Model supposed to come from?

missing library odoc.odoc

pinned odoc to your fork, pinned odoc2docset to this repo.
got this:

#=== ERROR while compiling odoc2docset.1.2.1 ==================================#
# context     2.0.3 | linux/x86_64 | ocaml-base-compiler.4.07.1 | pinned(git+https://github.com/jfeser/odoc2docset.git#7fc67711)
# path        ~/.opam/default/.opam-switch/build/odoc2docset.1.2.1
# command     ~/.opam/opam-init/hooks/sandbox.sh build dune build -p odoc2docset -j 15
# exit-code   1
# env-file    ~/.opam/log/odoc2docset-23425-d2d111.env
# output-file ~/.opam/log/odoc2docset-23425-d2d111.out
### output ###
# File "bin/dune", line 4, characters 24-33:
# 4 |  (libraries sqlite3 bos odoc.odoc odoc.model odoc.html lambdasoup logs logs.fmt logs.cli fmt.cli fmt.tty base stdio cmdliner))
#                             ^^^^^^^^^
# Error: Library "odoc.odoc" not found.
# Hint: try: dune external-lib-deps --missing -j 15 -p odoc2docset @@default

how to build this project

Is there some module missing ?

File "bin/main.ml", line 46, characters 18-40:
Error: Unbound module Model

let rec id_to_string =
  let module Id = Model.Paths.Identifier in
  ...

error with generating docket for CamomileLibrary

For some reason, when generating docket for every installed package, I get

odoc2docset: [WARNING] Could not find anchor node for val-write_std_json in Opam.docset/Contents/Resources/Documents/yojson/Yojson/index.html.
No unit for root: camomile::CamomileLibrary
odoc2docset: [ERROR] ("Failed to resolve."
/Users/nrolland/.opam/system/var/cache/odig/cache/zed/zed_edit.odoc)
No unit for root: camomile::CamomileLibrary
odoc2docset: [ERROR] ("Failed to resolve."
/Users/nrolland/.opam/system/var/cache/odig/cache/zed/zed_rope.odoc)
No unit for root: camomile::CamomileLibrary
odoc2docset: [ERROR] ("Failed to resolve."
/Users/nrolland/.opam/system/var/cache/odig/cache/zed/zed_re.odoc)
No unit for root: camomile::CamomileLibrary
odoc2docset: [ERROR] ("Failed to resolve."
/Users/nrolland/.opam/system/var/cache/odig/cache/zed/zed_utf8.odoc)
nrolland@mactoasty ~/$

Zed documentation fails on my system.
It might be useful to add a way to exclude a package from documentation generation

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.