Git Product home page Git Product logo

nebula-project-plugin's Introduction

Nebula Project Plugin

Provides healthy defaults for a Gradle project. Currently adds:

  • Builds Javadoc and Sources jars
  • Record information about the build and stores it in the .jar, via gradle-info-plugin
  • Easy specification of people involved in a project via gradle-contacts-plugin
  • Doesn't fail javadoc if there are none found

Nebula Facet Plugin

A routine pattern is wanting a new SourceSet with an accompanying Configuration for dependencies. We consider this another facet of your project and can be modeled via the Nebula Facet plugin. This plugin will create a SourceSet with the name provided, which extends the main SourceSet, and consequencely it'll create configurations for compile and runtime, which extends from the parent SourceSet. Their "classes" task will be wired up to the build task.

apply plugin: 'nebula-facet'
facets {
    examples
    performance
}

The previous definition would make a examples and performance SourceSet, so that code can go in src/examples/java and src/performance/java. It'll get four configurations: examplesCompile, examplesRuntime, performanceCompile, performanceRuntime. Those configuration will extends compile and runtime respectively. Each one can be configured to inherit from another SourceSet, e.g.

facets {
    functional {
        parentSourceSet = 'test'
    }
}

That will cause the functionCompile to extend from testCompile, and functionalRuntime to extend from testRuntime, since those are the configurations from the "test" SourceSet.

Test Facets

If "Test" is in the facet name, then a Test task would be created (though it'll still inherit from the "main" SourceSet", use the above configuration to make the test facet extends from the test SourceSet). E.g.

facets {
    integTest
}

That will create a test task called integTest in addition to the integTest SourceSet. The parent SourceSet can still be overriden like above, and the task name can be set:

facets {
    integTest {
        parentSourceSet = 'main'
        testTaskName = 'integrationTest'
    }
}

Nebula IntegTest Plugin

A correlary from the Facet Plugin is a concrete Facet, this plugin provide one specifically for Integration Tests. By applying this plugin, you'll get a integrationTest Test task, where sources go in src/integTest/java and dependencies can go into integTestCompile and integTestRuntime (which extend from the test SourceSet). E.g.

apply plugin: 'nebula-integtest'

nebula-project-plugin's People

Contributors

rspieldenner avatar jmcgarr avatar bmuschko avatar quidryan avatar cfieber avatar jkschneider avatar

Watchers

James Cloos avatar Philippe Ombredanne 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.