UNPKG

generator-gradle-springboot

Version:

Enables generating gradle/groovy based library and springboot application projects for mono-repo style project/microservice setup

58 lines (39 loc) 2.83 kB
# generator-gradle-springboot ![Node.js CI](https://github.com/amitmisra16/generator-gradle-springboot/workflows/Node.js%20CI/badge.svg) ![Node.js Package](https://github.com/amitmisra16/generator-gradle-springboot/workflows/Node.js%20Package/badge.svg) > ## Why another gradle and springboot based generator? Gradle has great scafolding capabilities for quickly bringing up a multi-module setup. There are few gaps here: * `app` is not a spring-boot based application. * Adding more than two `library` or `api` project. * The names of the `library`, `api` and `app` projects/modules are not configurable The [SpringInitializr](https://start.spring.io) helps in generating springboot based application with all the dependencies you need. In a way addresses the first issues but then how would add this generated app to existing build chain. ## Gradle-Springboot generator This plugin bridges the gap by enabling you to leverage multi-module setup capability of gralde with springboot based applications. You can declare the names of your library/api and application projects and the generator will scafold the code generated by gradle. In case of an application it adds basic `@SpringbootApplication` annotation to the main class. This plugin also utilizes Gradle's `buildSrc` conventions and appropriately scafolds library and application project's `build.gradle` files. ## Installation First, install [Yeoman](http://yeoman.io) and generator-gradle-springboot using [npm](https://www.npmjs.com/) (we assume you have pre-installed [node.js](https://nodejs.org/)). ```bash npm install -g yo npm install -g generator-gradle-springboot ``` Then generate your new project: ```bash yo gradle-springboot ``` ## Demo [![asciicast](https://asciinema.org/a/aWGSMYssshX5dYbOndYazgz0Y.png)](https://asciinema.org/a/aWGSMYssshX5dYbOndYazgz0Y) ## Getting To Know Yeoman * Yeoman has a heart of gold. * Yeoman is a person with feelings and opinions, but is very easy to work with. * Yeoman can be too opinionated at times but is easily convinced not to be. * Feel free to [learn more about Yeoman](http://yeoman.io/). ## License Apache-2.0 © [Amit Misra]() [npm-image]: https://badge.fury.io/js/generator-gradle-springboot.svg [npm-url]: https://npmjs.org/package/generator-gradle-springboot [travis-image]: https://travis-ci.com/amitmisra16/generator-gradle-springboot.svg?branch=master [travis-url]: https://travis-ci.com/amitmisra16/generator-gradle-springboot [daviddm-image]: https://david-dm.org/amitmisra16/generator-gradle-springboot.svg?theme=shields.io [daviddm-url]: https://david-dm.org/amitmisra16/generator-gradle-springboot [coveralls-image]: https://coveralls.io/repos/amitmisra16/generator-gradle-springboot/badge.svg [coveralls-url]: https://coveralls.io/r/amitmisra16/generator-gradle-springboot