куда jitpack загружает артефакты сборки?

Этот проект hello world работает нормально, но где файл hello_api-latest.jar? (Независимо от того, что клиенту на самом деле не нужен JAR, он все равно должен загрузиться.)

JAR находится на пути к классам:

thufir@mordor:~/NetBeansProjects/hello_client$ 
thufir@mordor:~/NetBeansProjects/hello_client$ gradle clean build;java -jar build/libs/hello_client.jar
:clean
:compileJava
:processResources UP-TO-DATE
:classes
:jar
:startScripts
:distTar
:distZip
:assemble
:compileTestJava UP-TO-DATE
:processTestResources UP-TO-DATE
:testClasses UP-TO-DATE
:test UP-TO-DATE
:check UP-TO-DATE
:build

BUILD SUCCESSFUL

Total time: 1.229 secs

hello world

thufir@mordor:~/NetBeansProjects/hello_client$ 
thufir@mordor:~/NetBeansProjects/hello_client$ jar -xf build/libs/hello_client.jar 
thufir@mordor:~/NetBeansProjects/hello_client$ 
thufir@mordor:~/NetBeansProjects/hello_client$ cat META-INF/MANIFEST.MF 
Manifest-Version: 1.0
Main-Class: net.bounceme.mordor.Main
Class-Path: hello_api-latest.jar

thufir@mordor:~/NetBeansProjects/hello_client$ 
thufir@mordor:~/NetBeansProjects/hello_client$ tree build
build
├── classes
│   └── main
│       └── net
│           └── bounceme
│               └── mordor
│                   └── Main.class
├── dependency-cache
├── distributions
│   ├── hello_client.tar
│   └── hello_client.zip
├── libs
│   └── hello_client.jar
├── scripts
│   ├── hello_client
│   └── hello_client.bat
└── tmp
    ├── compileJava
    │   └── emptySourcePathRef
    └── jar
        └── MANIFEST.MF

13 directories, 7 files
thufir@mordor:~/NetBeansProjects/hello_client$ 

файл сборки:

apply plugin: 'java'
apply plugin: 'application'

sourceCompatibility = '1.8'
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
if (!hasProperty('mainClass')) {
    ext.mainClass = 'Main'
}

mainClassName = 'net.bounceme.mordor.Main'

repositories {
    mavenCentral()
    maven { url "https://jitpack.io" }

}

dependencies {
    testCompile group: 'junit', name: 'junit', version: '4.10'
    compile 'com.github.THUFIR:hello_api:latest'

}



jar {
    manifest {
        attributes ('Main-Class': 'net.bounceme.mordor.Main',
            "Class-Path": configurations.compile.collect { it.getName() }.join(' '))
    }
}

Примечательно, что зависимость jitpack не отображается в Netbeans:

введите здесь описание изображения

Артефакт сборки в конце журнала может показаться указать, что JAR, hello_api-latest.jar, был найден:

latest
commit 244c611ae48dc95daee544fbfb5767ae1f961e10
Author: thufir 
Date:   Fri Feb 5 05:39:47 2016 -0800

    increment

submodule status:
Run gradle build
Gradle build script
WARNING: Gradle wrapper not found. Please add. Using default gradle to build.
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8

------------------------------------------------------------
Gradle 2.7
------------------------------------------------------------

Build time:   2015-09-14 07:26:16 UTC
Build number: none
Revision:     c41505168da69fb0650f4e31c9e01b50ffc97893

Groovy:       2.3.10
Ant:          Apache Ant(TM) version 1.9.3 compiled on December 23 2013
JVM:          1.8.0_60 (Oracle Corporation 25.60-b23)
OS:           Linux 3.14.32-xxxx-grs-ipv6-64 amd64

0m0.684s
Getting a list of gradle tasks
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
Found javadoc task

WARNING:
Gradle 'install' task not found. Please add the 'maven' or 'android-maven' plugin.
See the documentation and examples: https://jitpack.io/docs/

Looking for android-library
Looking for com.android.application
Adding maven plugin
Running: gradle clean -Pgroup=com.github.THUFIR -Pversion=latest -xtest install
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
:clean UP-TO-DATE
:compileJava
Download https://repo1.maven.org/maven2/org/codehaus/groovy/groovy-all/2.4.1/groovy-all-2.4.1.pom
Download https://repo1.maven.org/maven2/org/codehaus/groovy/groovy-all/2.4.1/groovy-all-2.4.1.jar
:processResources UP-TO-DATE
:classes
:jar
:install

BUILD SUCCESSFUL

Total time: 1.883 secs
Gradle exit code 0
Looking for artifacts...
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
Found artifact: com.github.THUFIR:hello_api:latest
EXIT_CODE=0
2016-03-10T09:47:34.133966887Z
Exit code: 0

Build artifacts:
com.github.THUFIR:hello_api:latest

Files: 
com/github/THUFIR/hello_api/latest
com/github/THUFIR/hello_api/latest/build.log
com/github/THUFIR/hello_api/latest/hello_api-latest.jar
com/github/THUFIR/hello_api/latest/hello_api-latest.pom
com/github/THUFIR/hello_api/latest/hello_api-latest.pom.md5
com/github/THUFIR/hello_api/latest/hello_api-latest.pom.sha1

но куда он был скачан куда?

смотрите также:

https://stackoverflow.com/a/22724504/262852

https://stackoverflow.com/a/30094915/262852

https://stackoverflow.com/a/34329145/262852

ОБНОВЛЕНИЕ

вот:

thufir@mordor:~$ 
thufir@mordor:~$ tree .gradle/ | grep latest
│       │   │       └── latest
│       │   │           │   └── hello_api-latest.pom
│       │   │               └── hello_api-latest.jar
│       │   │   │       └── latest
│       │   │   │       └── latest
thufir@mordor:~$ 

person Thufir    schedule 10.03.2016    source источник


Ответы (1)


Как и любая внешняя зависимость, она загружается в кеш gradle. Расположение по умолчанию: ~/.gradle

person RaGe    schedule 10.03.2016
comment
stackoverflow.com/a/34329145/262852 говорит, что он должен быть взорван в build/intermediates как взорванный JAR..? - person Thufir; 10.03.2016
comment
Это неправда. Я полагаю, что @GabrieleMariotti отвечал в контексте этого вопроса/ответа, который на самом деле касается исходящего двоичного файла, а не входящего, как в данном случае. Папка build/intermediates заполняется в процессе сборки на этапе создания двоичного файла aap или aar. Внешние загруженные зависимости по умолчанию сюда не попадают. - person RaGe; 10.03.2016