Skip to content

Generating scaladocs

Keith Alcock edited this page Aug 20, 2021 · 4 revisions

Installation

Info on how to write the Scaladoc

Two plugins involved (see project/plugins.sbt):

  • sbt-site (generates a site with the Scaladoc)
  • sbt-ghpages (will publish the site to GitHub Pages)

Commands

Development

sbt previewSite (command comes with sbt-site)

  • will start a local webserver that will show the current version of the Scaladoc (in your branch)
  • open localhost:4000 (if it doesn't open automatically)
  • i.e., use to preview before you push!

Publish

It seems that an ssh key is now required to perform this operation. If the plugins have difficulty checking out the gh-pages branch to ~/.sbt/ghpages/*/org.clulab/eidos, you may be missing an ssh key. Follow the instructions to install one and see if it helps.

sbt ghpagesPushSite

  • this may take a minute or two
  • this pushes to https://clulab.github.io/eidos/latest/api/org/clulab/wm/eidos/index.html

Notes

  • Scaladoc comments on private methods don't appear (neither do the methods...)
  • those with experience suggest that the @param, @return, and @constructor (for a class) are the most important tags to include