=sbt Fix StreamOperatorsIndexGenerator on Windows (#31347)
This commit is contained in:
parent
bfafb8cf0f
commit
dc480ac9da
2 changed files with 12 additions and 5 deletions
|
|
@ -101,8 +101,8 @@ For example, following snippet will fall with timeout exception:
|
|||
```scala
|
||||
...
|
||||
.toMat(StreamConverters.asInputStream().mapMaterializedValue { inputStream =>
|
||||
inputStream.read() // this could block forever
|
||||
...
|
||||
inputStream.read() // this could block forever
|
||||
...
|
||||
}).run()
|
||||
```
|
||||
|
||||
|
|
@ -514,6 +514,7 @@ For more background see the @ref[Error Handling in Streams](../stream-error.md)
|
|||
* [orElse](Source-or-Flow/orElse.md)
|
||||
* [Partition](Partition.md)
|
||||
* [prefixAndTail](Source-or-Flow/prefixAndTail.md)
|
||||
* [preMaterialize](Source-or-Flow/preMaterialize.md)
|
||||
* [preMaterialize](Sink/preMaterialize.md)
|
||||
* [prepend](Source-or-Flow/prepend.md)
|
||||
* [prependLazy](Source-or-Flow/prependLazy.md)
|
||||
|
|
|
|||
|
|
@ -248,9 +248,15 @@ object StreamOperatorsIndexGenerator extends AutoPlugin {
|
|||
s"There must be at least 5 lines in $file, including the title, description, category link and an empty line between each two of them")
|
||||
// This forces the short description to be on a single line. We could make this smarter,
|
||||
// but 'forcing' the short description to be really short seems nice as well.
|
||||
val description = lines(2)
|
||||
.replaceAll("ref:?\\[(.*?)\\]\\(", "ref[$1](" + file.getAbsolutePath.replaceFirst(".*/([^/]+/).*", "$1"))
|
||||
require(!description.isEmpty, s"description in $file must be non-empty, single-line description at the 3rd line")
|
||||
val separator = java.io.File.separatorChar
|
||||
val path =
|
||||
if (separator != '/')
|
||||
file.getAbsolutePath.replace(separator, '/')
|
||||
else
|
||||
file.getAbsolutePath
|
||||
val description =
|
||||
lines(2).replaceAll("ref:?\\[(.*?)\\]\\(", "ref[$1](" + path.replaceFirst(".*/([^/]+/).*", "$1"))
|
||||
require(description.nonEmpty, s"description in $file must be non-empty, single-line description at the 3rd line")
|
||||
val categoryLink = lines(4)
|
||||
require(
|
||||
categoryLink.startsWith("@ref"),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue