使用gradle复制构建工件

时间:2016-12-14 16:09:48

标签: java android maven gradle aar

我使用gradle构建android库并将其推送到远程maven存储库。有没有办法获得结果------Before modifications 0: goto 0 ------After modifications 0: getstatic #32 = Field java.lang.System.out(Ljava/io/PrintStream;) 3: ldc #34 = "injected into loop" 5: invokevirtual #40 = Method java.io.PrintStream.println((Ljava/lang/String;)V) 8: goto 8 ------Attempting to create instance of modified class Exception in thread "main" java.lang.VerifyError: Expecting a stackmap frame at branch target 8 Exception Details: Location: EmptyLoopTest$EmptyLoopClass.emptyLoopMethod()V @8: goto Reason: Expected stackmap frame at this location. Bytecode: 0x0000000: b200 2012 22b6 0028 a700 00 Stackmap Table: same_frame(@0) at java.lang.Class.getDeclaredConstructors0(Native Method) at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671) at java.lang.Class.getConstructor0(Class.java:3075) at java.lang.Class.newInstance(Class.java:412) at EmptyLoopTest.testEmptyLoopModification(EmptyLoopTest.java:35) at EmptyLoopTest.main(EmptyLoopTest.java:68) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:147) Process finished with exit code 1 pom文件并将其复制到项目的根目录?

以下是发布到maven的任务(它在图书馆项目aar中)

build.gradle

1 个答案:

答案 0 :(得分:1)

您使用的是maven插件吗?如果是这样,您将在${project.buildDir}/poms下找到生成的poms和工件,例如来自install任务配置。

也可以使用doLast uploadArchives