Skip to content

Commit

Permalink
Add local publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
Justin Ryan committed Oct 11, 2012
1 parent 6d4a854 commit 61bd2b0
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 14 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ Thumbs.db
# Editor Files #
################
*~
*.swp

# Gradle Files #
################
Expand Down
26 changes: 12 additions & 14 deletions gradle/release.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,21 @@ unSnapshotVersion.dependsOn checkUpdateNeeded
checkUpdateNeeded.dependsOn checkCommitNeeded
checkCommitNeeded.dependsOn initScmPlugin

// Call out to compile against internal repository
task uploadArtifactory(type: GradleBuild) {
startParameter = project.gradle.startParameter.newInstance()
startParameter.addInitScript( file('gradle/netflix-oss.gradle') )
startParameter.getExcludedTaskNames().add('check')
tasks = [ 'build', 'artifactoryPublish' ]
[
uploadIvyLocal: 'uploadLocal',
uploadArtifactory: 'artifactoryPublish', // Call out to compile against internal repository
buildWithArtifactory: 'build' // Build against internal repository
].each { key, value ->
// Call out to compile against internal repository
task "${key}"(type: GradleBuild) {
startParameter = project.gradle.startParameter.newInstance()
startParameter.addInitScript( file('gradle/netflix-oss.gradle') )
startParameter.getExcludedTaskNames().add('check')
tasks = [ 'build', value ]
}
}
task releaseArtifactory(dependsOn: [checkSnapshotDependencies, uploadArtifactory])


task buildWithArtifactory(type: GradleBuild) {
startParameter = project.gradle.startParameter.newInstance()
startParameter.addInitScript( file('gradle/netflix-oss.gradle') )
startParameter.getExcludedTaskNames().add('check')
tasks = [ 'build' ]
}

// Ensure upload happens before taggging but after all pre-checks
releaseArtifactory.dependsOn checkSnapshotDependencies
createReleaseTag.dependsOn releaseArtifactory
Expand Down

0 comments on commit 61bd2b0

Please sign in to comment.