-
-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7a39343
commit fca28f3
Showing
5 changed files
with
71 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package lila.search | ||
package client | ||
|
||
import smithy4s.http4s.* | ||
import org.http4s.Uri | ||
import org.http4s.client.Client | ||
import cats.effect.IO | ||
import cats.effect.Resource | ||
|
||
// the package under which the scala code was generated | ||
import lila.search.spec.* | ||
|
||
object Clients: | ||
def apply(http4sClient: Client[IO], uri: Uri): Resource[IO, SearchService[IO]] = | ||
SimpleRestJsonBuilder | ||
.apply(SearchService) | ||
.client(http4sClient) | ||
.uri(uri) | ||
.resource |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
version = "3.8.1" | ||
runner.dialect = scala213 | ||
|
||
align.preset = more | ||
maxColumn = 110 | ||
spaces.inImportCurlyBraces = true | ||
rewrite.rules = [SortModifiers] | ||
rewrite.redundantBraces.stringInterpolation = true | ||
|
||
fileOverride { | ||
"glob:**/build.sbt" { | ||
runner.dialect = scala213 | ||
} | ||
"glob:**/project/**" { | ||
runner.dialect = scala213 | ||
} | ||
|
||
"glob:**/modules/api/**" { | ||
runner.dialect = scala3 | ||
} | ||
|
||
"glob:**/modules/client/**" { | ||
runner.dialect = scala3 | ||
} | ||
|
||
"glob:**/modules/app/**" { | ||
runner.dialect = scala3 | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
addSbtPlugin("com.disneystreaming.smithy4s" % "smithy4s-sbt-codegen" % "0.18.16") | ||
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.9.2") | ||
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2") | ||
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.9.2") | ||
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2") | ||
addSbtPlugin("org.typelevel" % "sbt-tpolecat" % "0.5.1") | ||
ThisBuild / libraryDependencySchemes += "org.scala-lang.modules" %% "scala-xml" % VersionScheme.Always |