diff options
| author | Jim Lawson | 2017-01-05 10:09:11 -0800 |
|---|---|---|
| committer | Jim Lawson | 2017-01-05 10:09:11 -0800 |
| commit | efc367e883ffd8c0a239f04943e4bda5ce356da4 (patch) | |
| tree | 280daa55255c51f03600a65802c2274bc55d3176 | |
| parent | 8a1cdf15d131e086ddc9de6bfe8cd90ed7fb3eb7 (diff) | |
Fix ScalaDoc complaints; add sbt-site, sbt-ghpages boilerplate.
| -rw-r--r-- | build.sbt | 30 | ||||
| -rw-r--r-- | project/plugins.sbt | 13 | ||||
| -rw-r--r-- | root-doc.txt | 2 | ||||
| -rw-r--r-- | src/main/scala/firrtl/Compiler.scala | 4 | ||||
| -rw-r--r-- | src/main/scala/firrtl/Utils.scala | 2 |
5 files changed, 48 insertions, 3 deletions
@@ -1,4 +1,16 @@ +// See LICENSE for license details. +// sbt-site - sbt-ghpages + +site.settings + +site.includeScaladoc() + +ghpages.settings + +git.remoteRepo := "git@github.com:ucb-bar/firrtl.git" + +// Firrtl code organization := "edu.berkeley.cs" @@ -40,3 +52,21 @@ antlr4GenListener in Antlr4 := false // default = true antlr4PackageName in Antlr4 := Option("firrtl.antlr") +// ScalaDoc + +import UnidocKeys._ + +lazy val customUnidocSettings = unidocSettings ++ Seq ( + doc in Compile := (doc in ScalaUnidoc).value, + target in unidoc in ScalaUnidoc := crossTarget.value / "api" +) + +autoAPIMappings := true + +scalacOptions in Compile in doc ++= Seq( + "-diagrams", + "-diagrams-max-classes", "25", + "-doc-version", version.value, + "-doc-title", name.value, + "-doc-root-content", baseDirectory.value+"/root-doc.txt" +) diff --git a/project/plugins.sbt b/project/plugins.sbt new file mode 100644 index 00000000..e8a9bcef --- /dev/null +++ b/project/plugins.sbt @@ -0,0 +1,13 @@ +resolvers += Resolver.url("scalasbt", new URL("http://scalasbt.artifactoryonline.com/scalasbt/sbt-plugin-releases")) (Resolver.ivyStylePatterns) + +resolvers += Classpaths.sbtPluginReleases + +resolvers += "jgit-repo" at "http://download.eclipse.org/jgit/maven" + +addSbtPlugin("com.typesafe.sbt" % "sbt-ghpages" % "0.5.4") + +addSbtPlugin("com.typesafe.sbt" % "sbt-site" % "0.8.2") + +addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.6.1") + +addSbtPlugin("com.eed3si9n" % "sbt-unidoc" % "0.3.3") diff --git a/root-doc.txt b/root-doc.txt new file mode 100644 index 00000000..5bf31ab3 --- /dev/null +++ b/root-doc.txt @@ -0,0 +1,2 @@ +This is the documentation for Firrtl. + diff --git a/src/main/scala/firrtl/Compiler.scala b/src/main/scala/firrtl/Compiler.scala index 09e1df60..808fa435 100644 --- a/src/main/scala/firrtl/Compiler.scala +++ b/src/main/scala/firrtl/Compiler.scala @@ -28,8 +28,8 @@ case class AnnotationMap(annotations: Seq[Annotation]) { * @constructor Creates a CircuitState object * @param circuit The current state of the Firrtl AST * @param form The current form of the circuit - * @param annotations The current collection of [[Annotation]] - * @param renames A map of [[Named]] things that have been renamed. + * @param annotations The current collection of [[firrtl.annotations.Annotation Annotation]] + * @param renames A map of [[firrtl.annotations.Named Named]] things that have been renamed. * Generally only a return value from [[Transform]]s */ case class CircuitState( diff --git a/src/main/scala/firrtl/Utils.scala b/src/main/scala/firrtl/Utils.scala index 458e479d..bce8e1be 100644 --- a/src/main/scala/firrtl/Utils.scala +++ b/src/main/scala/firrtl/Utils.scala @@ -28,7 +28,7 @@ object Utils extends LazyLogging { result } - /** Removes all [[firrtl.ir.Empty]] statements and condenses + /** Removes all [[firrtl.ir.EmptyStmt]] statements and condenses * [[firrtl.ir.Block]] statements. */ def squashEmpty(s: Statement): Statement = s map squashEmpty match { |
