Skip to content

Commit 585c350

Browse files
committed
add in documenation for targeting an individual file
Also bump the docusaurus version
1 parent c957fe2 commit 585c350

File tree

4 files changed

+13
-6
lines changed

4 files changed

+13
-6
lines changed

docs/installation.md

+7
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,13 @@ contained, by default the `docs/` directory is used.
151151
+ --in mydocs
152152
```
153153

154+
You can also target an individual file by passing it to `--in`.
155+
156+
```diff
157+
coursier launch org.scalameta:mdoc_@SCALA_BINARY_VERSION@:@VERSION@ -- \
158+
+ --in mydocs/readme.md
159+
```
160+
154161
Use `--site.VARIABLE=value` to add site variables that can be referenced from
155162
markdown as `@@VARIABLE@`.
156163

mdoc-sbt/src/main/scala/mdoc/MdocPlugin.scala

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ object MdocPlugin extends AutoPlugin {
1818
)
1919
val mdocIn =
2020
settingKey[File](
21-
"Input directory containing markdown sources to be processed by mdoc. " +
22-
"Defaults to the toplevel docs/ directory."
21+
"Input directory containing markdown sources to be processed by mdoc, or an " +
22+
"individual file that you'd like to target. Defaults to the toplevel docs/ directory."
2323
)
2424
val mdocOut =
2525
settingKey[File](

mdoc/src/main/scala/mdoc/internal/cli/Settings.scala

+3-3
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ class Section(val name: String) extends StaticAnnotation
3535
case class Settings(
3636
@Section("Common options")
3737
@Description(
38-
"The input directory containing markdown and other documentation sources. " +
39-
"Markdown files will be processed by mdoc while other files will be copied " +
40-
"verbatim to the output directory."
38+
"The input directory containing markdown and other documentation sources " +
39+
"or an individual file that you'd like to target. Markdown files will be " +
40+
"processed by mdoc while other files will be copied verbatim to the output directory."
4141
)
4242
@ExtraName("i")
4343
in: AbsolutePath,

website/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
"rename-version": "docusaurus-rename-version"
1010
},
1111
"devDependencies": {
12-
"docusaurus": "1.6.2"
12+
"docusaurus": "1.14.4"
1313
}
1414
}

0 commit comments

Comments
 (0)