Skip to content

Commit

Permalink
Fixed windows line endings parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
laughedelic committed Mar 4, 2014
1 parent 09c5c80 commit 4a70381
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ resolvers += "laughedelic maven releases" at "http://dl.bintray.com/laughedelic/
// OR if you use bintray-sbt plugin:
// resolvers += bintray.Opts.resolver.repo("laughedelic", "maven")

libraryDependencies += "laughedelic" %% "literator-lib" % "0.5.0"
libraryDependencies += "laughedelic" %% "literator-lib" % "0.5.1"
```

Then you can use `literate` method of `File` to generate docs for your sources. For example:
Expand Down
2 changes: 1 addition & 1 deletion docs/src/lib/FileUtils.scala.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,4 @@ Just writing to the file
[FileUtils.scala]: FileUtils.scala.md
[LanguageMap.scala]: LanguageMap.scala.md
[LiteratorParsers.scala]: LiteratorParsers.scala.md
[package.scala]: package.scala.md
[package.scala]: package.scala.md
2 changes: 1 addition & 1 deletion docs/src/lib/LiteratorParsers.scala.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ A _chunk_ of source is either a block comment, or code
}
}

def eol: PS = "\n"
def eol: PS = "\r".? ~> "\n"
def spaces: PS = regex("""[ \t]*""".r)
def char: PS = regex(".".r) // any symbol except EOL
def emptyLine: PS = spaces ~> eol
Expand Down
2 changes: 1 addition & 1 deletion lib/src/main/scala/LiteratorParsers.scala
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ case class LiteratorParsers(val lang: Language) extends RegexParsers {
}
}

def eol: PS = "\n"
def eol: PS = "\r".? ~> "\n"
def spaces: PS = regex("""[ \t]*""".r)
def char: PS = regex(".".r) // any symbol except EOL
def emptyLine: PS = spaces ~> eol
Expand Down
1 change: 1 addition & 0 deletions notes/0.5.1.markdown
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fixed line endings handling (Windows CRLF) (#15)
20 changes: 10 additions & 10 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
resolvers += "Era7 Releases" at "http://releases.era7.com.s3.amazonaws.com"
resolvers ++= Seq(
"Era7 maven releases" at "http://releases.era7.com.s3.amazonaws.com",
"Era7 maven snapshots" at "http://snapshots.era7.com.s3.amazonaws.com",
"sbt-taglist-releases" at "http://johanandren.github.com/releases/",
"laughedelic maven releases" at "http://dl.bintray.com/laughedelic/maven",
Resolver.url("laughedelic sbt-plugins", url("http://dl.bintray.com/laughedelic/sbt-plugins"))(Resolver.ivyStylePatterns),
Resolver.url("bintray-sbt-plugin-releases", url("http://dl.bintray.com/content/sbt/sbt-plugin-releases"))(Resolver.ivyStylePatterns)
)

addSbtPlugin("ohnosequences" % "nice-sbt-settings" % "0.3.1")

addSbtPlugin("ohnosequences" % "sbt-github-release" % "0.1.0")

resolvers += Resolver.url(
"bintray-sbt-plugin-releases",
url("http://dl.bintray.com/content/sbt/sbt-plugin-releases"))(
Resolver.ivyStylePatterns)
addSbtPlugin("ohnosequences" % "nice-sbt-settings" % "0.4.0-M2")

addSbtPlugin("me.lessis" % "bintray-sbt" % "0.1.1")

Expand All @@ -18,4 +18,4 @@ addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.3.0")
addSbtPlugin("net.databinder" % "conscript-plugin" % "0.3.5")

// itself for testing:
addSbtPlugin("laughedelic" % "literator-plugin" % "0.5.0-SNAPSHOT")
// addSbtPlugin("laughedelic" % "literator-plugin" % "0.5.1-SNAPSHOT")
2 changes: 1 addition & 1 deletion version.sbt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version in ThisBuild := "0.5.0"
version in ThisBuild := "0.5.1-SNAPSHOT"

0 comments on commit 4a70381

Please sign in to comment.