Skip to content

Commit

Permalink
Merge pull request #148 from raboof/patch-2
Browse files Browse the repository at this point in the history
Document another common `snip.xxx.base_dir`
  • Loading branch information
pvlugter authored Sep 19, 2017
2 parents ccabcf7 + c085979 commit 316e665
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions docs/src/main/paradox/features/snippet-inclusion.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,8 @@ either in the page's front matter or globally like this (for example):
```sbt
paradoxProperties in Compile ++= Map(
"snip.foo.base_dir" -> "../../../some/dir",
"snip.test.base_dir" -> s"${(sourceDirectory in Test).value}/scala/org/example"
"snip.test.base_dir" -> s"${(sourceDirectory in Test).value}/scala/org/example",
"snip.project.base_dir" -> (baseDirectory in ThisBuild).value.getAbsolutePath
)
```

Expand All @@ -129,6 +130,6 @@ for example:

If a placeholder directory is relative (like `$foo$` in this example) it'll be based of the path of the respective page
it is used in. Also, *paradox* always auto-defines the placeholder `$root$` to denote the absolute path of the
SBT project's root directory.
sbt (sub)project's root directory.

**Note**: Using this feature will not allow GitHub to follow the snippet links correctly on the web UI.

0 comments on commit 316e665

Please sign in to comment.