Settings

case class Settings(@Section("Common options") @Description("The input directory or regular file containing markdown and other documentation sources that should be processed. ".+("Markdown files are processed by mdoc while non-markdown files are copied verbatim to the output directory. ").+("Can be repeated to process multiple input directories/files.")) @ExtraName("i") in: List[AbsolutePath], @Description("The output directory or regular file where you\'d like to generate your markdown or other documentation sources. ".+("Must be repeated to match the number of `--in` arguments and must be a directory when the matching `--in` argument is a directory.")) @ExtraName("o") out: List[AbsolutePath], @Description("Start a file watcher and incrementally re-generate the site on file save.") @ExtraName("w") watch: Boolean, @Description("Instead of generating a new site, report an error if generating the site would produce a diff ".+("against an existing site. Useful for asserting in CI that a site is up-to-date.")) @ExtraName("test") check: Boolean, @Description("Disable link hygiene analysis so that no warnings are reported for dead links.") noLinkHygiene: Boolean, @Description("Link hygiene analysis reports dead links as errors. Useful for asserting in CI that the site contains no dead links. This setting has no effect in watch mode. It is also mutually exclusive with --no-link-hygiene, if both are set, link hygiene is disabled.") checkLinkHygiene: Boolean, @Description("Include additional diagnostics for debugging potential problems.") verbose: Boolean, @Description("Key/value pairs of variables to replace through @VAR@. ".+("For example, the flag \'--site.VERSION 1.0.0\' will replace appearances of \'@VERSION@\' in ").+("markdown files with the string 1.0.0")) site: Map[String, String], @Section("Compiler options") @Description("Classpath to use when compiling Scala code examples. ".+("Defaults to the current thread\'s classpath.").+("You can use Coursier\'s fetch command to generate the classpath for you:").+("`--classpath $(cs fetch --classpath org::artifact:version)`")) classpath: String, @Description("Space separated list of compiler flags such as \'-Xplugin:kind-projector.jar -deprecation -Yrangepos\'. ".+("Defaults to the value of \'scalacOptions\' in the \'mdoc.properties\' resource file, if any. ").+("When using sbt-mdoc, update the `scalacOptions` sbt setting instead of passing --scalac-options to `mdocExtraArguments`.")) scalacOptions: String, @Description("Remove all files in the output directory before generating a new site.") cleanTarget: Boolean, @Section("LiveReload options") @Description("Don\'t start a LiveReload server under --watch mode.") noLivereload: Boolean, @Description("Which port the LiveReload server should listen to. ".+("If the port is not free, another free port close to this number is used.")) port: Int, @Description("Which hostname the LiveReload server should listen to") host: String, @Section("Less common options") @Description("Print out a help message and exit") help: Boolean, @Description("Print out usage instructions and exit") usage: Boolean, @Description("Print out the version number and exit") version: Boolean, @Description("Set of file extensions to treat as markdown files.") markdownExtensions: List[String], @Description("Glob to filter which files to process. Defaults to all files. ".+("Example: --include **/example.md will process only files with the name example.md.")) @ExtraName("includePath") include: List[PathMatcher], @Description("Glob to filter which files from exclude from processing. Defaults to no files. ".+("Example: --include users/**.md --exclude **/example.md will process all files in the users/ directory ").+("excluding files named example.md.")) @ExtraName("excludePath") exclude: List[PathMatcher], @Description("Use relative filenames when reporting error messages. ".+("Useful for producing consistent docs on a local machine and CI. ")) reportRelativePaths: Boolean, @Description("The encoding to use when reading and writing files.") charset: Charset, @Description("The working directory to use for making relative paths absolute.") cwd: AbsolutePath, @Description("Allow indented code fence blocks") allowCodeFenceIndented: Boolean, @Hidden stringModifiers: List[StringModifier], @Hidden postModifiers: List[PostModifier], @Hidden preModifiers: List[PreModifier], @Hidden @Description("The input stream to listen for enter key during file watching.") inputStream: InputStream, @Hidden @Description("The width of the screen, used to line wrap pretty-printed objects.") screenWidth: Int, @Hidden @Description("The height of the screen, used to truncate large pretty-printed objects.") screenHeight: Int, @Hidden @Description("The generator for header IDs, defaults to GitHub ID generator") headerIdGenerator: String => String, @Hidden @Description("The pretty printer for variables") variablePrinter: Variable => String, @Hidden @Description("The Coursier logger used to report progress bars when downloading dependencies") coursierLogger: Logger)
Companion:
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Concrete methods

def addSite(extraVariables: Map[String, String]): Settings
def isExplicitlyExcluded(path: RelativePath): Boolean
def isFileWatching: Boolean
def isIncluded(path: RelativePath): Boolean
def onLoad(reporter: Reporter): Unit
def toInputFile(infile: AbsolutePath): Option[InputFile]
override def toString: String
Definition Classes
Any
def withWorkingDirectory(dir: AbsolutePath): Settings

Inherited methods

def productElementNames: Iterator[String]
Inherited from:
Product
def productIterator: Iterator[Any]
Inherited from:
Product

Concrete fields

val isMarkdownFileExtension: Set[String]
val outputByInput: Map[AbsolutePath, AbsolutePath]