Skip to content

Commit

Permalink
Enable license header plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
Justin Ryan committed Aug 17, 2012
1 parent cc1b04c commit 0f0c611
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 6 deletions.
4 changes: 3 additions & 1 deletion build.gradle
Expand Up @@ -4,6 +4,7 @@ ext.githubProjectName = rootProject.name // TEMPLATE: change to match github pro

buildscript {
repositories { mavenCentral() }
apply from: file('gradle/buildscript.gradle'), to: buildscript
}

allprojects {
Expand All @@ -14,7 +15,7 @@ allprojects {
apply from: file('gradle/convention.gradle')
apply from: file('gradle/maven.gradle')
apply from: file('gradle/check.gradle')
//apply from: file('gradle/license.gradle') // Waiting for re-release
apply from: file('gradle/license.gradle')

subprojects {
// Closure to configure all the POM with extra info, common to all projects
Expand Down Expand Up @@ -44,6 +45,7 @@ subprojects {
}

project(':template-client') {
apply plugin: 'java'
dependencies {
compile 'org.slf4j:slf4j-api:1.6.3'
compile 'com.sun.jersey:jersey-client:1.11'
Expand Down
2 changes: 1 addition & 1 deletion codequality/HEADER
@@ -1,4 +1,4 @@
Copyright 2012 Netflix, Inc.
Copyright ${year} Netflix, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
3 changes: 3 additions & 0 deletions gradle/buildscript.gradle
@@ -0,0 +1,3 @@
// Executed in context of buildscript
dependencies { classpath 'nl.javadude.gradle.plugins:license-gradle-plugin:0.6.0' }

12 changes: 8 additions & 4 deletions gradle/license.gradle
@@ -1,5 +1,9 @@
buildscript {
dependencies { classpath 'nl.javadude.gradle.plugins:license-gradle-plugin:0.5' }
}
// Dependency for plugin was set in buildscript.gradle

apply plugin: nl.javadude.gradle.plugins.license.LicensePlugin
subprojects {
apply plugin: 'license' //nl.javadude.gradle.plugins.license.LicensePlugin
license {
header rootProject.file('codequality/HEADER')
ext.year = Calendar.getInstance().get(Calendar.YEAR)
}
}

0 comments on commit 0f0c611

Please sign in to comment.