aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzongyu <zzy2529420793@gmail.com>2020-07-19 20:12:25 +0800
committerzongyu <zzy2529420793@gmail.com>2020-07-19 20:12:25 +0800
commit2079ef593386ada75e3afc6750e11a2165896569 (patch)
tree6a3a66adc4c4b020f8b9a04c97ccfc59b3ff42bb
parentformat a right string for java-virtuals/* (diff)
downloadjava-ebuilder-2079ef593386ada75e3afc6750e11a2165896569.tar.gz
java-ebuilder-2079ef593386ada75e3afc6750e11a2165896569.tar.bz2
java-ebuilder-2079ef593386ada75e3afc6750e11a2165896569.zip
rename source code file to ${P}-sources.[extension]
Signed-off-by: zongyu <zzy2529420793@gmail.com>
-rw-r--r--src/main/java/org/gentoo/java/ebuilder/maven/MavenEbuilder.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/org/gentoo/java/ebuilder/maven/MavenEbuilder.java b/src/main/java/org/gentoo/java/ebuilder/maven/MavenEbuilder.java
index da3a01b..38a8bf8 100644
--- a/src/main/java/org/gentoo/java/ebuilder/maven/MavenEbuilder.java
+++ b/src/main/java/org/gentoo/java/ebuilder/maven/MavenEbuilder.java
@@ -31,7 +31,7 @@ public class MavenEbuilder {
* Pattern for checking whether download tarball name matches expected name.
*/
private static final Pattern PATTERN_TARBALL_NAME
- = Pattern.compile("^.*/\\$\\{P\\}((?:\\.tar)\\.\\S+|(?:\\.jar))$");
+ = Pattern.compile("^.*/\\$\\{P\\}-sources.((?:\\.tar)\\.\\S+|(?:\\.jar))$");
/**
* Generates ebuild from the collected information at the specified path.
@@ -232,7 +232,7 @@ public class MavenEbuilder {
return srcUri;
}
- return srcUri + " -> " + "${P}" + matcher.group(1);
+ return srcUri + " -> " + "${P}-sources" + matcher.group(1);
}
/**
@@ -876,7 +876,7 @@ public class MavenEbuilder {
writer.println();
writer.println("src_unpack() {");
writer.println("\tmkdir -p ${S}/${JAVA_SRC_DIR}");
- writer.println("\tunzip ${DISTDIR}/${P}.jar -d ${S}/${JAVA_SRC_DIR} || die");
+ writer.println("\tunzip ${DISTDIR}/${P}-sources.jar -d ${S}/${JAVA_SRC_DIR} || die");
if (mavenProject.hasTests()) {
writer.println("\tmkdir -p ${JAVA_TEST_SRC_DIR}");