From 9d62369e1417086ccd72134af537e91fd062a61c Mon Sep 17 00:00:00 2001 From: Jimin Hsieh Date: Sat, 16 Dec 2017 14:58:20 +0800 Subject: [PATCH] Fix broken link of build-in keys in docs (#555) --- src/reference/00-Getting-Started/05-Basic-Def.md | 2 +- src/reference/00-Getting-Started/06-Task-Graph.md | 4 ++-- src/reference/00-Getting-Started/08-Library-Dependencies.md | 4 ++-- src/reference/00-Getting-Started/11-Custom-Settings.md | 4 ++-- src/reference/es/00-Getting-Started/05-Basic-Def.md | 2 +- src/reference/ja/00-Getting-Started/05-Basic-Def.md | 2 +- src/reference/ja/00-Getting-Started/06-Task-Graph.md | 4 ++-- .../ja/00-Getting-Started/08-Library-Dependencies.md | 2 +- src/reference/ja/00-Getting-Started/11-Custom-Settings.md | 2 +- src/reference/zh-cn/00-Getting-Started/05-Basic-Def.md | 2 +- .../zh-cn/00-Getting-Started/07-More-About-Settings.md | 4 ++-- .../zh-cn/00-Getting-Started/08-Library-Dependencies.md | 4 ++-- src/reference/zh-cn/00-Getting-Started/11-Custom-Settings.md | 4 ++-- 13 files changed, 20 insertions(+), 20 deletions(-) diff --git a/src/reference/00-Getting-Started/05-Basic-Def.md b/src/reference/00-Getting-Started/05-Basic-Def.md index 4eb9cc728..d21add363 100644 --- a/src/reference/00-Getting-Started/05-Basic-Def.md +++ b/src/reference/00-Getting-Started/05-Basic-Def.md @@ -124,7 +124,7 @@ There are three flavors of key: #### Built-in Keys The built-in keys are just fields in an object called -[Keys](../sxr/sbt/Keys.scala.html). A `build.sbt` implicitly has an +[Keys](../api/sbt/Keys\$.html). A `build.sbt` implicitly has an `import sbt.Keys._`, so `sbt.Keys.name` can be referred to as `name`. #### Custom Keys diff --git a/src/reference/00-Getting-Started/06-Task-Graph.md b/src/reference/00-Getting-Started/06-Task-Graph.md index 0a21221df..613cd4146 100644 --- a/src/reference/00-Getting-Started/06-Task-Graph.md +++ b/src/reference/00-Getting-Started/06-Task-Graph.md @@ -34,7 +34,7 @@ another task or setting. The value method is special and may only be called in the argument to `:=` (or, `+=` or `++=`, which we'll see later). As a first example, consider defining the `scalacOption` that depends on -`update` and `clean` tasks. Here are the definitions of these keys (from [Keys](../sxr/sbt/Keys.scala.html)). +`update` and `clean` tasks. Here are the definitions of these keys (from [Keys](../api/sbt/Keys\$.html)). **Note**: The values calculated below are nonsensical for `scalaOptions`, and it's just for demonstration purpose only: @@ -277,7 +277,7 @@ Here's how it should look on the sbt shell: [success] Total time: 0 s, completed Jan 2, 2017 11:44:51 PM ``` -Next, take these two keys (from [Keys](../sxr/sbt/Keys.scala.html)): +Next, take these two keys (from [Keys](../api/sbt/Keys\$.html)): ```scala val scalacOptions = taskKey[Seq[String]]("Options for the Scala compiler.") diff --git a/src/reference/00-Getting-Started/08-Library-Dependencies.md b/src/reference/00-Getting-Started/08-Library-Dependencies.md index 138791b9b..4987bb3c3 100644 --- a/src/reference/00-Getting-Started/08-Library-Dependencies.md +++ b/src/reference/00-Getting-Started/08-Library-Dependencies.md @@ -94,7 +94,7 @@ libraryDependencies += groupID % artifactID % revision % configuration ``` `libraryDependencies` is declared in -[Keys](../sxr/sbt/Keys.scala.html#sbt.Keys.libraryDependencies) like +[Keys](../api/sbt/Keys\$.html#libraryDependencies:sbt.SettingKey[Seq[sbt.librarymanagement.ModuleID]]) like this: ```scala @@ -195,7 +195,7 @@ resolvers += "Sonatype OSS Snapshots" at "https://oss.sonatype.org/content/repos ``` The `resolvers` key is defined in -[Keys](../sxr/sbt/Keys.scala.html#sbt.Keys.resolvers) like this: +[Keys](../api/sbt/Keys\$.html#resolvers:sbt.SettingKey[Seq[sbt.librarymanagement.Resolver]]) like this: ```scala val resolvers = settingKey[Seq[Resolver]]("The user-defined additional resolvers for automatically managed dependencies.") diff --git a/src/reference/00-Getting-Started/11-Custom-Settings.md b/src/reference/00-Getting-Started/11-Custom-Settings.md index 391b74a87..cc34315b5 100644 --- a/src/reference/00-Getting-Started/11-Custom-Settings.md +++ b/src/reference/00-Getting-Started/11-Custom-Settings.md @@ -21,7 +21,7 @@ Getting Started Guide, especially [build.sbt][Basic-Def] and ### Defining a key -[Keys](../sxr/sbt/Keys.scala.html) is packed with examples +[Keys](../api/sbt/Keys\$.html) is packed with examples illustrating how to define keys. Most of the keys are implemented in [Defaults](../sxr/sbt/Defaults.scala.html). @@ -29,7 +29,7 @@ Keys have one of three types. `SettingKey` and `TaskKey` are described in [.sbt build definition][Basic-Def]. Read about `InputKey` on the [Input Tasks][Input-Tasks] page. -Some examples from [Keys](../sxr/sbt/Keys.scala.html): +Some examples from [Keys](../api/sbt/Keys\$.html): ```scala val scalaVersion = settingKey[String]("The version of Scala used for building.") diff --git a/src/reference/es/00-Getting-Started/05-Basic-Def.md b/src/reference/es/00-Getting-Started/05-Basic-Def.md index 2ab847b6e..740e6d15c 100644 --- a/src/reference/es/00-Getting-Started/05-Basic-Def.md +++ b/src/reference/es/00-Getting-Started/05-Basic-Def.md @@ -168,7 +168,7 @@ Existen tres tipos de llaves: #### Built-in Keys (Llaves ya incluídas) Las llaves ya incluídas son simplemente campos de un objeto llamado -[Keys](../sxr/sbt/Keys.scala.html). Un archivo `build.sbt` tiene +[Keys](../api/sbt/Keys\$.html). Un archivo `build.sbt` tiene implícitamente un `import sbt.Keys._`, de modo que `sbt.Keys.name` puede ser referido como `name`. diff --git a/src/reference/ja/00-Getting-Started/05-Basic-Def.md b/src/reference/ja/00-Getting-Started/05-Basic-Def.md index 58daaf52c..187e26a69 100644 --- a/src/reference/ja/00-Getting-Started/05-Basic-Def.md +++ b/src/reference/ja/00-Getting-Started/05-Basic-Def.md @@ -2,7 +2,7 @@ out: Basic-Def.html --- - [Keys]: ../../sxr/sbt/Keys.scala.html + [Keys]: ../../api/sbt/Keys\$.html [Task-Graph]: Task-Graph.html [Bare-Def]: Bare-Def.html [Full-Def]: Full-Def.html diff --git a/src/reference/ja/00-Getting-Started/06-Task-Graph.md b/src/reference/ja/00-Getting-Started/06-Task-Graph.md index 7657b5758..1f92e9950 100644 --- a/src/reference/ja/00-Getting-Started/06-Task-Graph.md +++ b/src/reference/ja/00-Getting-Started/06-Task-Graph.md @@ -34,7 +34,7 @@ out: Task-Graph.html 最初の例として、`update` と `clean` というタスクに依存した形で `scalacOption` を定義したいとする。 -([Keys](../sxr/sbt/Keys.scala.html) より)以下の二つのキーを例に説明する。 +([Keys](../api/sbt/Keys\$.html) より)以下の二つのキーを例に説明する。 **注意**: ここで計算される `scalacOptions` の値はナンセンスなもので、説明のためだけのものだ: @@ -267,7 +267,7 @@ sbt シェルで試すとこうなるはずだ: [success] Total time: 0 s, completed Jan 2, 2017 11:44:51 PM ``` -次に ([Keys](../sxr/sbt/Keys.scala.html) より) 以下の二つのキーを例に説明する: +次に ([Keys](../api/sbt/Keys\$.html) より) 以下の二つのキーを例に説明する: ```scala val scalacOptions = taskKey[Seq[String]]("Options for the Scala compiler.") diff --git a/src/reference/ja/00-Getting-Started/08-Library-Dependencies.md b/src/reference/ja/00-Getting-Started/08-Library-Dependencies.md index f016148c1..a58a1b11f 100644 --- a/src/reference/ja/00-Getting-Started/08-Library-Dependencies.md +++ b/src/reference/ja/00-Getting-Started/08-Library-Dependencies.md @@ -2,7 +2,7 @@ out: Library-Dependencies.html --- - [Keys]: ../../sxr/sbt/Keys.scala.html + [Keys]: ../../api/sbt/Keys\$.html [Apache Ivy]: https://ant.apache.org/ivy/ [Ivy revisions]: https://ant.apache.org/ivy/history/2.3.0-rc1/ivyfile/dependency.html#revision [Extra attributes]: https://ant.apache.org/ivy/history/2.3.0-rc1/concept.html#extra diff --git a/src/reference/ja/00-Getting-Started/11-Custom-Settings.md b/src/reference/ja/00-Getting-Started/11-Custom-Settings.md index b4472ab4f..9a0ea2d80 100644 --- a/src/reference/ja/00-Getting-Started/11-Custom-Settings.md +++ b/src/reference/ja/00-Getting-Started/11-Custom-Settings.md @@ -9,7 +9,7 @@ out: Custom-Settings.html [Input-Tasks]: ../../docs/Input-Tasks.html [Plugins]: ../../docs/Plugins.html [Tasks]: ../../docs/Tasks.html - [Keys]: ../../sxr/sbt/Keys.scala.html + [Keys]: ../../api/sbt/Keys\$.html [Defaults]: ../../sxr/sbt/Defaults.scala.html [Scaladocs-IO]: ../api/sbt/io/IO\$.html diff --git a/src/reference/zh-cn/00-Getting-Started/05-Basic-Def.md b/src/reference/zh-cn/00-Getting-Started/05-Basic-Def.md index 656f2a41b..4b48c80a4 100644 --- a/src/reference/zh-cn/00-Getting-Started/05-Basic-Def.md +++ b/src/reference/zh-cn/00-Getting-Started/05-Basic-Def.md @@ -122,7 +122,7 @@ lazy val root = (project in file(".")) #### 内置的 Keys -内置的 keys 实际上是对象 [Keys](../../sxr/sbt/Keys.scala.html) 的字段。`build.sbt` 会隐式包含 `import sbt.Keys._`,所以可以通过 `name` 取到 `sbt.Keys.name`。 +内置的 keys 实际上是对象 [Keys](../../api/sbt/Keys\$.html) 的字段。`build.sbt` 会隐式包含 `import sbt.Keys._`,所以可以通过 `name` 取到 `sbt.Keys.name`。 #### 自定义 Keys diff --git a/src/reference/zh-cn/00-Getting-Started/07-More-About-Settings.md b/src/reference/zh-cn/00-Getting-Started/07-More-About-Settings.md index 908bfcecc..fc3c8fecb 100644 --- a/src/reference/zh-cn/00-Getting-Started/07-More-About-Settings.md +++ b/src/reference/zh-cn/00-Getting-Started/07-More-About-Settings.md @@ -123,7 +123,7 @@ sourceGenerators in Compile += Def.task { 在 [.sbt 构建定义][Basic-Def] 中提到过,当你通过 `:=` 或其他方法创建一个设置时,task key 创建的是 `Setting[Task[T]]` 而不是 `Setting[T]`。 Setting 可以是 Task 的输入,但 Task 不能是 Setting 的输入。 -以这两个 key 为例(从 [Keys](../../sxr/sbt/Keys.scala.html) 中): +以这两个 key 为例(从 [Keys](../../api/sbt/Keys\$.html) 中): ```scala val scalacOptions = taskKey[Seq[String]]("Options for the Scala compiler.") @@ -152,4 +152,4 @@ checksums := scalacOptions.value ```scala cleanFiles += file("coverage-report-" + name.value + ".txt") -``` \ No newline at end of file +``` diff --git a/src/reference/zh-cn/00-Getting-Started/08-Library-Dependencies.md b/src/reference/zh-cn/00-Getting-Started/08-Library-Dependencies.md index 7d22ccd75..d23362a7d 100644 --- a/src/reference/zh-cn/00-Getting-Started/08-Library-Dependencies.md +++ b/src/reference/zh-cn/00-Getting-Started/08-Library-Dependencies.md @@ -69,7 +69,7 @@ libraryDependencies += groupID % artifactID % revision libraryDependencies += groupID % artifactID % revision % configuration ``` -`libraryDependencies` 在 [Keys](../../sxr/sbt/Keys.scala.html#sbt.Keys.libraryDependencies) 中像这样声明: +`libraryDependencies` 在 [Keys](../../api/sbt/Keys\$.html#libraryDependencies:sbt.SettingKey[Seq[sbt.librarymanagement.ModuleID]]) 中像这样声明: ```scala val libraryDependencies = settingKey[Seq[ModuleID]]("Declares managed dependencies.") @@ -142,7 +142,7 @@ resolvers += name at location resolvers += "Sonatype OSS Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots" ``` -`resolvers` key 在 [Keys](../../sxr/sbt/Keys.scala.html#sbt.Keys.resolvers) 中像这样定义: +`resolvers` key 在 [Keys](../../api/sbt/Keys\$.html#resolvers:sbt.SettingKey[Seq[sbt.librarymanagement.Resolver]]) 中像这样定义: ```scala val resolvers = settingKey[Seq[Resolver]]("用户为托管依赖定义的额外的解析器。") diff --git a/src/reference/zh-cn/00-Getting-Started/11-Custom-Settings.md b/src/reference/zh-cn/00-Getting-Started/11-Custom-Settings.md index ccf85bc02..1e195a3bc 100644 --- a/src/reference/zh-cn/00-Getting-Started/11-Custom-Settings.md +++ b/src/reference/zh-cn/00-Getting-Started/11-Custom-Settings.md @@ -19,11 +19,11 @@ out: Custom-Settings.html ### 定义一个键 -[这里](../../sxr/sbt/Keys.scala.html)介绍了如何定义键。大多数的默认键定义在[这里](../../sxr/sbt/Defaults.scala.html)。 +[这里](../../api/sbt/Keys\$.html)介绍了如何定义键。大多数的默认键定义在[这里](../../sxr/sbt/Defaults.scala.html)。 键有三种类型。`SettingKey` 和 `TaskKey` 在 [.sbt 构建定义][Basic-Def]讲解。关于 `InputKey` 的内容在[输入任务][Input-Tasks]页面。 -列举一些来自 [Keys](../../sxr/sbt/Keys.scala.html) 的例子: +列举一些来自 [Keys](../../api/sbt/Keys\$.html) 的例子: ```scala val scalaVersion = settingKey[String]("scala的版本")