Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
lihaoyi committed Oct 7, 2024
1 parent eba11f9 commit f140105
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions os/src/ZipOps.scala
Original file line number Diff line number Diff line change
Expand Up @@ -248,12 +248,11 @@ object unzip {
source: os.Path,
excludePatterns: Seq[Regex] = List(),
includePatterns: Seq[Regex] = List()
): Iterator[os.SubPath] = {
val zipFile = new ZipFile(source.toIO)
): Generator[os.SubPath] = {
for {
entry <- zipFile.entries().asScala
if zip.shouldInclude(entry.getName, excludePatterns, includePatterns)
} yield os.SubPath(entry.getName)
(zipEntry, zipInputStream) <-
streamRaw(os.read.stream(source), excludePatterns, includePatterns)
} yield os.SubPath(zipEntry.getName)
}

/**
Expand Down

0 comments on commit f140105

Please sign in to comment.