From 2edb4dcbb6adb87d2c1ddbc80f049ca09129b921 Mon Sep 17 00:00:00 2001 From: xuwei-k <6b656e6a69@gmail.com> Date: Sat, 24 Jun 2023 20:05:52 +0900 Subject: [PATCH] fix typo --- internal/util-collection/src/test/scala/SettingsTest.scala | 2 +- .../src/main/scala/sbt/internal/util/EscHelpers.scala | 2 +- main-command/src/main/scala/sbt/BasicKeys.scala | 2 +- .../src/main/scala/sbt/internal/server/Server.scala | 2 +- .../src/main/scala/sbt/internal/server/ServerHandler.scala | 2 +- main/src/main/scala/sbt/BackgroundJobService.scala | 2 +- main/src/main/scala/sbt/InteractionService.scala | 2 +- main/src/main/scala/sbt/UpperStateOps.scala | 4 ++-- main/src/main/scala/sbt/internal/SessionSettings.scala | 6 +++--- main/src/main/scala/sbt/nio/FileChanges.scala | 2 +- main/src/main/scala/sbt/nio/Settings.scala | 2 +- main/src/main/scala/sbt/plugins/DependencyTreeKeys.scala | 2 +- notes/1.1.0.markdown | 2 +- .../sbt/internal/bsp/ScalaTestClassesParams.scala | 2 +- protocol/src/main/contraband/bsp.contra | 2 +- run/src/main/scala/sbt/Fork.scala | 2 +- server-test/src/test/scala/testpkg/BuildServerTest.scala | 4 ++-- 17 files changed, 21 insertions(+), 21 deletions(-) diff --git a/internal/util-collection/src/test/scala/SettingsTest.scala b/internal/util-collection/src/test/scala/SettingsTest.scala index 72d37ddab..00cf122fb 100644 --- a/internal/util-collection/src/test/scala/SettingsTest.scala +++ b/internal/util-collection/src/test/scala/SettingsTest.scala @@ -70,7 +70,7 @@ object SettingsTest extends Properties("settings") { ).toSeq { - // Note: This causes a cycle refernec error, quite frequently. + // Note: This causes a cycle reference error, quite frequently. checkKey(last, Some(nr - 1), evaluate(setting(chk, value(0)) +: derivedSettings)) :| "Not derived?" } && { checkKey(last, None, evaluate(derivedSettings)) :| "Should not be derived" diff --git a/internal/util-logging/src/main/scala/sbt/internal/util/EscHelpers.scala b/internal/util-logging/src/main/scala/sbt/internal/util/EscHelpers.scala index 4fe3060a8..3ffa1bd6c 100644 --- a/internal/util-logging/src/main/scala/sbt/internal/util/EscHelpers.scala +++ b/internal/util-logging/src/main/scala/sbt/internal/util/EscHelpers.scala @@ -32,7 +32,7 @@ object EscHelpers { * * The CSI (control sequence instruction) codes start with ESC + '['. This is for testing the second character. * - * There is an additional CSI (one character) that we could test for, but is not frequnetly used, and we don't + * There is an additional CSI (one character) that we could test for, but is not frequently used, and we don't * check for it. * * cf. http://en.wikipedia.org/wiki/ANSI_escape_code#CSI_codes diff --git a/main-command/src/main/scala/sbt/BasicKeys.scala b/main-command/src/main/scala/sbt/BasicKeys.scala index fd7b75d17..f01b1f6a4 100644 --- a/main-command/src/main/scala/sbt/BasicKeys.scala +++ b/main-command/src/main/scala/sbt/BasicKeys.scala @@ -145,7 +145,7 @@ object BasicKeys { ) private[sbt] val detachStdio = AttributeKey[Boolean]( "detach-stdio", - "Toggles wheter or not to close system in, out and error when the server starts.", + "Toggles whether or not to close system in, out and error when the server starts.", 1000 ) } diff --git a/main-command/src/main/scala/sbt/internal/server/Server.scala b/main-command/src/main/scala/sbt/internal/server/Server.scala index 83aeb6b31..272929899 100644 --- a/main-command/src/main/scala/sbt/internal/server/Server.scala +++ b/main-command/src/main/scala/sbt/internal/server/Server.scala @@ -188,7 +188,7 @@ private[sbt] object Server { IO.write(tokenfile, CompactPrinter(jsonToken), IO.utf8, true) } - /** Set the persmission of the file such that the only the owner can read/write it. */ + /** Set the permission of the file such that the only the owner can read/write it. */ private[this] def ownerOnly(file: File): Unit = { def acl(owner: UserPrincipal) = { val builder = AclEntry.newBuilder diff --git a/main-command/src/main/scala/sbt/internal/server/ServerHandler.scala b/main-command/src/main/scala/sbt/internal/server/ServerHandler.scala index 7f78de2d4..b503e503c 100644 --- a/main-command/src/main/scala/sbt/internal/server/ServerHandler.scala +++ b/main-command/src/main/scala/sbt/internal/server/ServerHandler.scala @@ -31,7 +31,7 @@ object ServerHandler { lazy val fallback: ServerHandler = ServerHandler({ handler => ServerIntent( onRequest = { case x => handler.log.debug(s"Unhandled request received: ${x.method}: $x") }, - onResponse = { case x => handler.log.debug(s"Unhandled responce received") }, + onResponse = { case x => handler.log.debug(s"Unhandled response received") }, onNotification = { case x => handler.log.debug(s"Unhandled notification received: ${x.method}: $x") }, diff --git a/main/src/main/scala/sbt/BackgroundJobService.scala b/main/src/main/scala/sbt/BackgroundJobService.scala index 65ebe7a08..6dc8deb81 100644 --- a/main/src/main/scala/sbt/BackgroundJobService.scala +++ b/main/src/main/scala/sbt/BackgroundJobService.scala @@ -45,7 +45,7 @@ abstract class BackgroundJobService extends Closeable { start(logger, file)._2.apply() } - /** Same as shutown. */ + /** Same as shutdown. */ def close(): Unit /** Shuts down all background jobs. */ diff --git a/main/src/main/scala/sbt/InteractionService.scala b/main/src/main/scala/sbt/InteractionService.scala index 24fa62104..61edd7a34 100644 --- a/main/src/main/scala/sbt/InteractionService.scala +++ b/main/src/main/scala/sbt/InteractionService.scala @@ -9,7 +9,7 @@ package sbt /** - * InteractionService provides an abstration over standard input. + * InteractionService provides an abstraction over standard input. * In the future this could be used to ask for inputs from * other forms of sbt clients such as thin clients and IDEs. */ diff --git a/main/src/main/scala/sbt/UpperStateOps.scala b/main/src/main/scala/sbt/UpperStateOps.scala index d0da94305..93c8b3944 100644 --- a/main/src/main/scala/sbt/UpperStateOps.scala +++ b/main/src/main/scala/sbt/UpperStateOps.scala @@ -19,12 +19,12 @@ trait UpperStateOps extends Any { /** * ProjectRef to the current project of the state session that can be change using - * `project` commmand. + * `project` command. */ def currentRef: ProjectRef /** - * Current project of the state session that can be change using `project` commmand. + * Current project of the state session that can be change using `project` command. */ def currentProject: ResolvedProject diff --git a/main/src/main/scala/sbt/internal/SessionSettings.scala b/main/src/main/scala/sbt/internal/SessionSettings.scala index 9b5d4e1f5..a8abd1ccc 100755 --- a/main/src/main/scala/sbt/internal/SessionSettings.scala +++ b/main/src/main/scala/sbt/internal/SessionSettings.scala @@ -47,9 +47,9 @@ final case class SessionSettings( ) /** - * Modifiy the current state. + * Modify the current state. * - * @param build The buid with which we scope new settings. + * @param build The build with which we scope new settings. * @param project The project reference with which we scope new settings. * @param eval The mechanism to compile new settings. * @return A new SessionSettings object @@ -298,7 +298,7 @@ list, list-all Prints a numbered list of session settings defined. The numbers may be used to remove individual settings or ranges of settings using 'remove'. For 'list', only the settings for the current project are printed. - For 'list-all', all settings in all projets are printed. + For 'list-all', all settings in all projects are printed. remove diff --git a/main/src/main/scala/sbt/nio/FileChanges.scala b/main/src/main/scala/sbt/nio/FileChanges.scala index d07240403..a35139f26 100644 --- a/main/src/main/scala/sbt/nio/FileChanges.scala +++ b/main/src/main/scala/sbt/nio/FileChanges.scala @@ -23,7 +23,7 @@ import java.nio.file.Path * @param modified the files that have been modified. This should be empty when no previous list of * files is available. * @param unmodified the files that have no changes. This should be empty when no previous list of - * files is availab.e + * files is available */ final case class FileChanges( created: Seq[Path], diff --git a/main/src/main/scala/sbt/nio/Settings.scala b/main/src/main/scala/sbt/nio/Settings.scala index 610272786..06fd0fddd 100644 --- a/main/src/main/scala/sbt/nio/Settings.scala +++ b/main/src/main/scala/sbt/nio/Settings.scala @@ -260,7 +260,7 @@ private[sbt] object Settings { * Provides an automatically generated clean method for a task that provides fileOutputs. * * @param taskKey the task for which we add a custom clean implementation - * @return a task specificic clean implementation + * @return a task specific clean implementation */ @nowarn private[sbt] def cleanImpl[T: JsonFormat: ToSeqPath](taskKey: TaskKey[T]): Def.Setting[_] = { diff --git a/main/src/main/scala/sbt/plugins/DependencyTreeKeys.scala b/main/src/main/scala/sbt/plugins/DependencyTreeKeys.scala index 4d775a6ff..71ea74c5c 100644 --- a/main/src/main/scala/sbt/plugins/DependencyTreeKeys.scala +++ b/main/src/main/scala/sbt/plugins/DependencyTreeKeys.scala @@ -46,7 +46,7 @@ abstract class DependencyTreeKeys { "The boxes of nodes are painted with colors. Otherwise they're black." ) val dependencyDotNodeLabel = settingKey[(String, String, String) => String]( - "Returns a formated string of a dependency. Takes organization, name and version as parameters" + "Returns a formatted string of a dependency. Takes organization, name and version as parameters" ) val dependencyDotHeader = settingKey[String]( "The header of the dot file. (e.g. to set your preferred node shapes)" diff --git a/notes/1.1.0.markdown b/notes/1.1.0.markdown index 723c20c27..b7b951a56 100644 --- a/notes/1.1.0.markdown +++ b/notes/1.1.0.markdown @@ -44,7 +44,7 @@ - Adds a check for a change in sbt version before `reload`. [#1055][1055]/[#3673][3673] by [@RomanIakovlev][@RomanIakovlev] - Adds a new setting `insideCI`, which indicates that sbt is likely running in an Continuous Integration environment. [#3672][3672] by [@RomanIakovlev][@RomanIakovlev] - Adds `nameOption` to `Command` trait. [#3671][3671] by [@miklos-martin][@miklos-martin] -- Adds POSIX persmission operations in IO, such as `IO.chmod(..)`. [io#76][io76] by [@eed3si9n][@eed3si9n] +- Adds POSIX permission operations in IO, such as `IO.chmod(..)`. [io#76][io76] by [@eed3si9n][@eed3si9n] - Treat sbt 1 modules using Semantic Versioning in the eviction warning. [lm#188][lm188] by [@eed3si9n][@eed3si9n] - Uses kind-projector in the code. [#3650][3650] by [@dwijnand][@dwijnand] - Make `displayOnly` etc methods strict in `Completions`. [#3763][3763] by [@xuwei-k][@xuwei-k] diff --git a/protocol/src/main/contraband-scala/sbt/internal/bsp/ScalaTestClassesParams.scala b/protocol/src/main/contraband-scala/sbt/internal/bsp/ScalaTestClassesParams.scala index d7c4b9a39..c925139f2 100644 --- a/protocol/src/main/contraband-scala/sbt/internal/bsp/ScalaTestClassesParams.scala +++ b/protocol/src/main/contraband-scala/sbt/internal/bsp/ScalaTestClassesParams.scala @@ -7,7 +7,7 @@ package sbt.internal.bsp /** * Scala Test Class Request * The build target scala test options request is sent from the client to the server - * to query for the list of fully qualified names of test clases in a given list of targets. + * to query for the list of fully qualified names of test classes in a given list of targets. * @param originId An optional number uniquely identifying a client request. */ final class ScalaTestClassesParams private ( diff --git a/protocol/src/main/contraband/bsp.contra b/protocol/src/main/contraband/bsp.contra index e0f2fd36f..033143005 100644 --- a/protocol/src/main/contraband/bsp.contra +++ b/protocol/src/main/contraband/bsp.contra @@ -715,7 +715,7 @@ type ScalaTestParams { ## Scala Test Class Request ## The build target scala test options request is sent from the client to the server -## to query for the list of fully qualified names of test clases in a given list of targets. +## to query for the list of fully qualified names of test classes in a given list of targets. type ScalaTestClassesParams { targets: [sbt.internal.bsp.BuildTargetIdentifier] diff --git a/run/src/main/scala/sbt/Fork.scala b/run/src/main/scala/sbt/Fork.scala index 1bdf0127f..3335f53f3 100644 --- a/run/src/main/scala/sbt/Fork.scala +++ b/run/src/main/scala/sbt/Fork.scala @@ -155,7 +155,7 @@ object Fork { /** Use an arguments file if: * - we are on jdk >= 9 - * - sbt.argfile is unset or not falsy + * - sbt.argsfile is unset or not falsy * - the command line length would exceed MaxConcatenatedOptionLength */ private def shouldUseArgumentsFile(options: Seq[String]): Boolean = diff --git a/server-test/src/test/scala/testpkg/BuildServerTest.scala b/server-test/src/test/scala/testpkg/BuildServerTest.scala index 84edd316a..c694f1334 100644 --- a/server-test/src/test/scala/testpkg/BuildServerTest.scala +++ b/server-test/src/test/scala/testpkg/BuildServerTest.scala @@ -257,7 +257,7 @@ object BuildServerTest extends AbstractServerTest { s.contains(""""severity":2""") && s.contains("""missing type arguments for generic class java.util.List""") }, - "should send publishDiagnostics with serverity 2 for Hello.java" + "should send publishDiagnostics with severity 2 for Hello.java" ) assert( @@ -267,7 +267,7 @@ object BuildServerTest extends AbstractServerTest { s.contains(""""severity":1""") && s.contains("""incompatible types: int cannot be converted to java.lang.String""") }, - "should send publishDiagnostics with serverity 1 for Hello.java" + "should send publishDiagnostics with severity 1 for Hello.java" ) }