GithubHelp home page GithubHelp logo

dreamscale-io / gradle-templates Goto Github PK

View Code? Open in Web Editor NEW

This project forked from blackbaud/gradle-templates

0.0 5.0 0.0 412 KB

A gradle project templates plugin

License: Apache License 2.0

Groovy 100.00%

gradle-templates's Introduction

DreamScale Project Templates

This project is used to bootstrap new projects as well as adding to existing projects.

There are times during development where the easiest way forward is to copy a set of classes and then proceed renaming/deleting/etc. This project exists b/c that process is error prone and just generally sucks.

Initialization

This project requires a primary workspace directory to be configured - a default root directory for all subsequent operations.

The default workspace is .., the directory where you checked out the gradle-templates project. This value is stored in gradle/custom.gradle which is initialized when the plugin is first applied. Edit this file if you want to change the workspace directory.

Usage

There are two intended uses for this project - as a creator of new projects and augmentor of existing projects.

Run the ./gradlew tasks command and look at the group Template tasks to see a list of the available tasks.

Project Creation Tasks

The project creation tasks are only available when run from this project. All tasks require the project property repoName to be specified in order to identify the target directory.

createLibraryProject

Creates a basic gradle project with a simple build.gradle file.

Supported task options:

  • clean - if the target directory already exists, delete it

createDeployableProject

Creates a skeleton SpringBoot project (includes build.gradle, application class, and supporting classes)

Supported task options:

  • clean - if the target directory already exists, delete it
  • postgres - initializes the project with a postgres container and supporting files
  • serviceName - the name of the SpringBoot application entrypoint, defaults to the repository name, converted to upper camel-case
  • servicePackageName - the name of the core package (contains the application entrypoint), defaults to "org.dreamscale.${serviceName.toLowercase()}"

Project Augmentation Tasks

The project augmentation tasks are available when run from this project but also when the dreamscale-templates plugin is applied to another project like so...

buildscript {
    dependencies {
        classpath "org.dreamscale:gradle-templates:1.+"
    }
}

apply plugin: "dreamscale-templates"

In this case, the target directory will be the project which applies the plugin and the project property repoName will be ignored.

createRestResource

Creates a resource in an existing SpringBoot REST project (includes the Resource, ResourceSpec, ResourceWireSpec, etc)

  • You may need to update the package for application.properties swagger.resource.package if your resource does not live in org.dreamscale..resources

addPostgresContainer

Adds a Postgres docker container configuration to an existing project

Publishing to Bintray

Make sure you have a bintray account and are a member of the DreamScale organization

Open your user profile and retrieve your API Key

Execute bintray upload gw bintrayUpload -Pbintray.user=<bintray user> -Pbintray.apiKey=<api key>

Open the DreamScale gradle-templates package and click the Publish link

gradle-templates's People

Contributors

accolasia avatar blackbaud-anyacranmer avatar blackbaud-bethrichardson avatar blackbaud-caspardavey avatar blackbaud-chrisjenkins avatar blackbaud-christophercotar avatar blackbaud-craigpemberton avatar blackbaud-dihuynh avatar blackbaud-ericslater avatar blackbaud-erikbudtke avatar blackbaud-greghenry avatar blackbaud-isaacaggrey avatar blackbaud-johnholland avatar blackbaud-laurenhunter avatar blackbaud-mikelueders avatar blackbaud-mitchellmorris avatar blackbaud-ryanmckay avatar cjstehno avatar merscwog avatar mlueders avatar polopi avatar townsfolk avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

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.