Use maven2sbt as a Library

How to Use

Get immediate result

import java.io.File
import maven2sbt.core.Maven2Sbt
import maven2sbt.core.ScalaVersion
import cats._
Maven2Sbt[Id].buildSbtFromPomFile(
ScalaVersion("2.13.1"), new File("/path/to/pom.xml")
)
// Id[Either[Maven2SbtError, BuildSbt]]
// or
Maven2Sbt[Id].buildSbtFromInputStream(
ScalaVersion("2.13.1"), inputStream
)
// Id[Either[Maven2SbtError, BuildSbt]]

With Cats Effect

import java.io.File
import maven2sbt.core.Maven2Sbt
import maven2sbt.core.ScalaVersion
import cats.effect._
Maven2Sbt[IO].buildSbtFromPomFile(
ScalaVersion("2.13.1"), new File("/path/to/pom.xml")
)
// IO[Either[Maven2SbtError, BuildSbt]]
// or
Maven2Sbt[IO].buildSbtFromInputStream(
ScalaVersion("2.13.1"), inputStream
)
// IO[Either[Maven2SbtError, BuildSbt]]