From 22aec702f63cd35bae8e079ed53f4fdbcbcd21d8 Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Thu, 13 May 2021 17:35:38 -0700 Subject: [PATCH 1/2] readme updates, post-2.0.0 --- README.md | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 32d69df1..afa34cbc 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,19 @@ # scala-parser-combinators [](https://travis-ci.org/scala/scala-parser-combinators) -[](http://search.maven.org/#search%7Cga%7C1%7Cg%3Aorg.scala-lang.modules%20a%3Ascala-parser-combinators_2.11) [](http://search.maven.org/#search%7Cga%7C1%7Cg%3Aorg.scala-lang.modules%20a%3Ascala-parser-combinators_2.12) [](http://search.maven.org/#search%7Cga%7C1%7Cg%3Aorg.scala-lang.modules%20a%3Ascala-parser-combinators_2.13) +[](http://search.maven.org/#search%7Cga%7C1%7Cg%3Aorg.scala-lang.modules%20a%3Ascala-parser-combinators_3) ### Scala Standard Parser Combinator Library This library was originally part of the Scala standard library, but is now community-maintained, under the guidance of the Scala team at Lightbend. If you are interested in helping please contact [@Philippus](https://github.com/philippus) or [@SethTisue](https://github.com/SethTisue). -The latest stable release is 1.1.2. - -The 1.2.0-RCx series supports Scala 3. +The latest stable release is 2.0.0. ## Documentation - * [Current API](https://javadoc.io/page/org.scala-lang.modules/scala-parser-combinators_2.12/latest/scala/util/parsing/combinator/index.html) + * [Current API](https://javadoc.io/page/org.scala-lang.modules/scala-parser-combinators_2.13/latest/scala/util/parsing/combinator/index.html) * The [Getting Started](docs/Getting_Started.md) guide * A more complicated example, [Building a lexer and parser with Scala's Parser Combinators](https://enear.github.io/2016/03/31/parser-combinators/) * "Combinator Parsing", chapter 33 of [_Programming in Scala, Third Edition_](http://www.artima.com/shop/programming_in_scala), shows how to apply this library to e.g. parsing of arithmetic expressions. The second half of the chapter examines how the library is implemented. @@ -24,7 +22,7 @@ The 1.2.0-RCx series supports Scala 3. To depend on scala-parser-combinators in sbt, add something like this to your build.sbt: ``` -libraryDependencies += "org.scala-lang.modules" %% "scala-parser-combinators" % "1.1.2" +libraryDependencies += "org.scala-lang.modules" %% "scala-parser-combinators" % "2.0.0" ``` To support multiple Scala versions, see the example in [scala/scala-module-dependency-sample](https://github.com/scala/scala-module-dependency-sample). @@ -34,7 +32,7 @@ To support multiple Scala versions, see the example in [scala/scala-module-depen Scala-parser-combinators is also available for Scala.js and Scala Native: ``` -libraryDependencies += "org.scala-lang.modules" %%% "scala-parser-combinators" % "1.1.2" +libraryDependencies += "org.scala-lang.modules" %%% "scala-parser-combinators" % "2.0.0" ``` ## Example From c742e6b3b700bc7144a3e2a8927132c3c6ad7ea6 Mon Sep 17 00:00:00 2001 From: Seth Tisue Date: Thu, 13 May 2021 17:39:00 -0700 Subject: [PATCH 2/2] minor build.sbt updates --- build.sbt | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/build.sbt b/build.sbt index 55adb576..69a5219c 100644 --- a/build.sbt +++ b/build.sbt @@ -11,16 +11,21 @@ lazy val parserCombinators = crossProject(JVMPlatform, JSPlatform, NativePlatfor .settings( ScalaModulePlugin.scalaModuleSettings, name := "scala-parser-combinators", + + // once https://github.com/lightbend/mima/issues/630 is fixed and sbt-scala-module + // adopts the fixed version, we'll be able to just do: + // scalaModuleMimaPreviousVersion := Some("2.0.0"), + // but for the time being we must still: scalaModuleMimaPreviousVersion := (CrossVersion.partialVersion(scalaVersion.value) match { - // pending resolution of https://github.com/scalacenter/sbt-version-policy/issues/62 - case Some((3, _)) => None - case _ => Some("1.2.0-RC1") - }), + // pending resolution of https://github.com/scalacenter/sbt-version-policy/issues/62 + case Some((3, _)) => None + case _ => Some("1.2.0-RC1") + }), libraryDependencies += "junit" % "junit" % "4.13.2" % Test, libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % Test, // so we can `@nowarn` in test code, but only in test code, so the dependency - // doesn't leak downstream + // doesn't leak downstream. can be dropped when we drop 2.11 from the crossbuild libraryDependencies += "org.scala-lang.modules" %% "scala-collection-compat" % "2.4.4" % Test, apiMappings ++= scalaInstance.value.libraryJars.collect {