-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #236 from rundeck/exp/tool-module
Refactor gradle project structure
- Loading branch information
Showing
109 changed files
with
316 additions
and
175 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# | ||
# Copyright 2019 Rundeck, Inc. (http://rundeck.com) | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,8 @@ buildscript { | |
} | ||
plugins{ | ||
id 'de.fuerstenau.buildconfig' version '1.1.8' | ||
id 'maven' | ||
id 'maven-publish' | ||
} | ||
|
||
|
||
|
@@ -20,6 +22,8 @@ apply plugin: 'idea' | |
apply plugin: 'groovy' | ||
apply plugin: 'de.fuerstenau.buildconfig' | ||
|
||
group = 'org.rundeck.api' | ||
|
||
/** | ||
* Generates java source with embedded version info | ||
*/ | ||
|
@@ -78,4 +82,85 @@ artifacts { | |
archives testJar | ||
archives sourceJar | ||
archives javadocJar | ||
} | ||
} | ||
def pomConfig = { | ||
licenses { | ||
license { | ||
name 'The Apache Software License, Version 2.0' | ||
url 'http://www.apache.org/licenses/LICENSE-2.0.txt' | ||
distribution 'repo' | ||
} | ||
} | ||
scm { | ||
url 'https://github.com/rundeck/rundeck-cli' | ||
connection 'scm:git:[email protected]/rundeck/rundeck-cli.git' | ||
developerConnection 'scm:git:[email protected]:rundeck/rundeck-cli.git' | ||
} | ||
developers { | ||
developer { | ||
id('gschueler') | ||
name('Greg Schueler') | ||
email('[email protected]') | ||
} | ||
} | ||
} | ||
publishing { | ||
publications { | ||
rdApiClientPublication(MavenPublication) { | ||
from components.java | ||
artifact sourceJar | ||
artifact javadocJar | ||
artifact testJar | ||
|
||
pom.withXml { | ||
def root = asNode() | ||
root.appendNode('description', project.description ?: 'Rundeck API Library') | ||
root.appendNode('name', "Rundeck API Library ${project.version}") | ||
root.appendNode('url', 'https://github.com/rundeck/rundeck-cli') | ||
root.children().last() + pomConfig | ||
} | ||
|
||
} | ||
} | ||
} | ||
|
||
def bintrayUser = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER') | ||
def bintrayKey = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : | ||
System.getenv('BINTRAY_API_KEY') | ||
def bintrayUserOrg = project.hasProperty('bintrayUserOrg') ? project.property('bintrayUserOrg') : | ||
System.getenv('BINTRAY_USER_ORG') | ||
def bintrayRepo = project.hasProperty('bintrayRepo') ? project.property('bintrayRepo') : | ||
System.getenv('BINTRAY_REPO') | ||
|
||
if (bintrayUser && bintrayKey && bintrayRepo) { | ||
|
||
apply plugin: 'com.jfrog.bintray' | ||
bintray { | ||
user = bintrayUser | ||
key = bintrayKey | ||
publications = ['rdApiClientPublication'] | ||
|
||
dryRun = false | ||
publish = true | ||
override = true | ||
pkg { | ||
name = project.name | ||
repo = bintrayRepo | ||
if (bintrayUserOrg) { | ||
userOrg = bintrayUserOrg | ||
} | ||
licenses = ['Apache-2.0'] | ||
vcsUrl = 'https://github.com/rundeck/rundeck-cli.git' | ||
websiteUrl = 'https://github.com/rundeck/rundeck-cli' | ||
issueTrackerUrl = 'https://github.com/rundeck/rundeck-cli/issues' | ||
githubRepo = 'rundeck/rundeck-cli' //Optional Github repository | ||
githubReleaseNotesFile = 'README.md' //Optional Github readme file | ||
|
||
version { | ||
name = rpmVersion | ||
desc = "${description} ${rpmVersion}" | ||
vcsTag = "v${rpmVersion}" | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.