-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
directly support java-gradle-plugin projects (#115)
* directly support java-gradle-plugin projects * code style * Gradle isn't doing weird things after all
- Loading branch information
1 parent
d16a6c3
commit b77782a
Showing
9 changed files
with
194 additions
and
26 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
src/integrationTest/fixtures/passing_java_gradle_plugin_project/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,21 @@ | ||
plugins { | ||
id "java-gradle-plugin" | ||
id "com.vanniktech.maven.publish" | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
|
||
gradlePlugin { | ||
plugins { | ||
mavenPublishPlugin { | ||
// the id here should be different from the group id and artifact id | ||
id = 'com.example.test-plugin' | ||
implementationClass = 'com.vanniktech.maven.publish.test.TestPlugin' | ||
} | ||
} | ||
} | ||
|
||
apply from: "maven-publish.gradle" |
34 changes: 34 additions & 0 deletions
34
...ssing_java_gradle_plugin_project/expected/com.example.test-plugin.gradle.plugin-1.0.0.pom
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,34 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
<groupId>com.example.test-plugin</groupId> | ||
<artifactId>com.example.test-plugin.gradle.plugin</artifactId> | ||
<version>1.0.0</version> | ||
<url>https://github.com/vanniktech/gradle-maven-publish-plugin/</url> | ||
<licenses> | ||
<license> | ||
<name>The Apache Software License, Version 2.0</name> | ||
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url> | ||
<distribution>repo</distribution> | ||
</license> | ||
</licenses> | ||
<developers> | ||
<developer> | ||
<id>vanniktech</id> | ||
<name>Niklas Baudy</name> | ||
<url>https://github.com/vanniktech/</url> | ||
</developer> | ||
</developers> | ||
<scm> | ||
<connection>scm:git:git://github.com/vanniktech/gradle-maven-publish-plugin.git</connection> | ||
<developerConnection>scm:git:ssh://git@github.com/vanniktech/gradle-maven-publish-plugin.git</developerConnection> | ||
<url>https://github.com/vanniktech/gradle-maven-publish-plugin/</url> | ||
</scm> | ||
<dependencies> | ||
<dependency> | ||
<groupId>com.example</groupId> | ||
<artifactId>test-artifact</artifactId> | ||
<version>1.0.0</version> | ||
</dependency> | ||
</dependencies> | ||
</project> |
30 changes: 30 additions & 0 deletions
30
...egrationTest/fixtures/passing_java_gradle_plugin_project/expected/test-artifact-1.0.0.pom
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,30 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | ||
<modelVersion>4.0.0</modelVersion> | ||
<groupId>com.example</groupId> | ||
<artifactId>test-artifact</artifactId> | ||
<version>1.0.0</version> | ||
<name>Gradle Maven Publish Plugin Test Artifact</name> | ||
<description>Testing the Gradle Maven Publish Plugin</description> | ||
<url>https://github.com/vanniktech/gradle-maven-publish-plugin/</url> | ||
<licenses> | ||
<license> | ||
<name>The Apache Software License, Version 2.0</name> | ||
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url> | ||
<distribution>repo</distribution> | ||
</license> | ||
</licenses> | ||
<developers> | ||
<developer> | ||
<id>vanniktech</id> | ||
<name>Niklas Baudy</name> | ||
<url>https://github.com/vanniktech/</url> | ||
</developer> | ||
</developers> | ||
<scm> | ||
<connection>scm:git:git://github.com/vanniktech/gradle-maven-publish-plugin.git</connection> | ||
<developerConnection>scm:git:ssh://git@github.com/vanniktech/gradle-maven-publish-plugin.git</developerConnection> | ||
<url>https://github.com/vanniktech/gradle-maven-publish-plugin/</url> | ||
</scm> | ||
</project> |
17 changes: 17 additions & 0 deletions
17
...ava_gradle_plugin_project/src/main/java/com/vanniktech/maven/publish/test/TestPlugin.java
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,17 @@ | ||
package com.vanniktech.maven.publish.test; | ||
|
||
import org.gradle.api.Plugin; | ||
import org.gradle.api.Project; | ||
|
||
/** | ||
* Just a test class with Javadoc. | ||
*/ | ||
public class TestPlugin implements Plugin<Project> { | ||
/** | ||
* Main method which does something. | ||
* | ||
* @param args Command-line arguments passed to the program. | ||
*/ | ||
public void apply(Project project) { | ||
} | ||
} |
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
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