Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
feat: log detected orphaned gradle files + test
If a gralde manifest was detected early on but no dependencies were returned at all for it warn the user to look further as this file may not be included in a root level gradle file. Thus it could be orhpaned. It could have also failed in which case an error will pop up.
- Loading branch information
Showing
6 changed files
with
202 additions
and
26 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
Empty file.
Empty file.
5 changes: 5 additions & 0 deletions
5
test/acceptance/workspaces/gradle-with-orphaned-build-file/settings.gradle
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,5 @@ | ||
rootProject.name = 'root-proj' | ||
|
||
include 'subproj' | ||
|
||
|
51 changes: 51 additions & 0 deletions
51
test/acceptance/workspaces/gradle-with-orphaned-build-file/subproj/build.gradle
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,51 @@ | ||
apply plugin: 'java' | ||
apply plugin: 'maven' | ||
|
||
group = 'com.github.jitpack' | ||
|
||
sourceCompatibility = 1.8 // java 8 | ||
targetCompatibility = 1.8 | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
// Gradle 3+ will not pick up "compile" dependencies for "compileOnly" | ||
// Gradle 2 will, so for configuration-matching tests we use "runtime" | ||
runtime 'com.google.guava:guava:18.0' | ||
runtime 'batik:batik-dom:1.6' | ||
runtime 'commons-discovery:commons-discovery:0.2' | ||
compileOnly 'axis:axis:1.3' | ||
runtime 'com.android.tools.build:builder:2.3.0' | ||
} | ||
|
||
task sourcesJar(type: Jar, dependsOn: classes) { | ||
classifier = 'sources' | ||
from sourceSets.main.allSource | ||
} | ||
|
||
task javadocJar(type: Jar, dependsOn: javadoc) { | ||
classifier = 'javadoc' | ||
from javadoc.destinationDir | ||
} | ||
|
||
artifacts { | ||
archives sourcesJar | ||
archives javadocJar | ||
} | ||
|
||
// To specify a license in the pom: | ||
install { | ||
repositories.mavenInstaller { | ||
pom.project { | ||
licenses { | ||
license { | ||
name 'The Apache Software License, Version 2.0' | ||
url 'http://www.apache.org/licenses/LICENSE-2.0.txt' | ||
distribution 'repo' | ||
} | ||
} | ||
} | ||
} | ||
} |