initial jbang example

This commit is contained in:
Max Rydahl Andersen
2021-11-14 11:47:06 +01:00
parent 58e95b3c40
commit 48be3e092a
5 changed files with 92 additions and 0 deletions

21
jbang/jbangquarkus.java Executable file
View File

@@ -0,0 +1,21 @@
///usr/bin/env jbang "$0" "$@" ; exit $?
// Update the Quarkus version to what you want here or run jbang with
// `-Dquarkus.version=<version>` to override it.
//DEPS io.quarkus:quarkus-bom:${quarkus.version:2.4.0.Final}@pom
//DEPS io.quarkus:quarkus-resteasy
//JAVAC_OPTIONS -parameters
//FILES META-INF/resources/index.html=index.html
import javax.enterprise.context.ApplicationScoped;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
@Path("/hello")
@ApplicationScoped
public class jbangquarkus {
@GET
public String sayHello() {
return "Hello from Quarkus with jbang.dev";
}
}