Skip to content

ThoughtWorksInc/sbt-api-mappings

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
travis@localhost
Jul 29, 2017
5d9984d · Jul 29, 2017

History

72 Commits
Oct 28, 2016
Jul 29, 2017
Apr 1, 2016
Oct 29, 2016
Jul 10, 2015
Jul 10, 2015
Apr 15, 2016
Oct 29, 2016
Jan 31, 2016
Jul 29, 2017
Jan 31, 2016
Jul 29, 2017

Repository files navigation

sbt-api-mappings

Build Status

sbt-api-mappings is a Sbt plugin that fills apiMappings for common Scala libraries.

Motivation

Sometimes when you wrote ScalaDoc for your own classes, you may want to reference to documentation in some other libraries.

For example:

/**
 * My own class, which works with [[scala.Option]] and [[scalaz.Monad]].
 */
class MyClass(optionMonad: scalaz.Monad[Option])

Unfortunately when use run doc command in Sbt, you will receive a warning and the link would not be created.

/path/to/MyClass.scala:3: Could not find any member to link for "scala.Option".

This plugin resolves the problem.

Usage

Step 1: Add the following lines in your project/plugins.sbt:

addSbtPlugin("com.thoughtworks.sbt-api-mappings" % "sbt-api-mappings" % "latest.release")

Step 2: Reload the Sbt configuration:

> reload

Step 3: Generate your API documentation:

> doc

Now, open the API documentation in your browser, and you will find the links to the scala.Option and scalaz.Monad's documentation in your MyClass page.