Code Monkey home page Code Monkey logo

mill-spring-boot's Introduction

mill-spring-boot - Packaging Spring Boot Applications with Mill

Build Status (GitHub Actions) Test Coverage (Codecov.io)

Mill plugin to support packing of Spring Boot Applications.

Quickstart

Mill version 0.10.0 or newer is required.

import $ivy.`de.tototec::de.tobiasroeser.mill.spring.boot::0.0.1`

import mill._
import mill.scalalib._
import de.tobiasroeser.mill.spring.boot.SpringBootModule

object app extends JavaModule with SpringBootModule {
  override def springBootToolsVersion = "2.7.14"
}
# Run the Spring-Boot Application
$ mill app.run

# Package as executable Spring-Boot Application
$ mill app.springBootAssembly

Targets and Configuration

Your module needs to extend the de.tobiasroeser.mill.spring.boot.SpringBootModule trait. The following targets are available:

def springBootToolsVersion: T[String]

Required. Override it to specify the version of the Spring Boot tools.

def springBootAssembly: T[PathRef]

Package an (executable) JAR.

You can run the application with java -jar out/app/springBootAssembly.dest/out.jar.

def springBootPrependScript: T[String]

A script prepended to the resulting springBootAssembly to make it executable. This uses the same prepend script logic as Mill JavaModule#prependScript does, so it supports most Linux/Unix shells (probably not fish) as well as Windows cmd shell (the file needs a .bat or .cmd extension in that case). Set it to "" if you don’t want an executable JAR.

def springBootMainClass: T[String]

The main class holding the Spring Boot Application entrypoint. By default, the value of JavaModule.mainClass is used, when defined, otherwise Spring Boot will try to auto-detect it.

Download

You can download binary releases from Maven Central.

Please make sure to use the correct mill platform suffix matching your used mill version.

License

This project is published under the terms of the Apache License, version 2

About

Mill

Mill is a Scala-based open source build tool. In my opinion the best build tool for the JVM. It is fast, reliable and easy to understand.

Me

I am Tobias Roeser, a professional software developer who loves to create and use open source tools. I’m actively developing and maintaining mill as well as several mill plugins.

If you like my work, please star it on GitHub. You can also support me via GitHub Sponsors.

Contributing

If you found a bug or have a feature request, please open a new issue on GitHub. I also accept pull requests on GitHub.

Changelog

0.0.1 - 2023-07-21

  • Initial public release

mill-spring-boot's People

Contributors

dependabot[bot] avatar lefou avatar scala-steward avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Forkers

scala-steward

mill-spring-boot's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.