Principled code generation for Scala services
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
project
src/main/scala/com/twilio/swagger/sbt
.gitignore
LICENSE
README.md
RELEASING.md
build.sbt
sbt

README.md

sbt-guardrail

An SBT 1.x+ plugin for adding clients and servers generated by guardrail to your service.

Installation

project/plugins.sbt

addSbtPlugin("com.twilio" % "sbt-guardrail" % "0.37.1-M1")

build.sbt

/* Available arguments:
    specPath: java.io.File
    pkg: String
    dto: String
    framework: String
    tracing: Boolean
*/
guardrailTasks in Compile := List(
  Client(file("petstore.yaml")),
  Client(file("github.yaml"), pkg="com.example.clients.github"),
  Server(file("myserver.yaml"), pkg="com.example.server", tracing=true)
)