Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradle fix, and Documentation fix. #4

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,35 @@
# Nekos4J
[ ![Download](https://api.bintray.com/packages/adriantodt/maven/nekos4j/images/download.svg) ](https://bintray.com/adriantodt/maven/nekos4j/_latestVersion)
[![Jitpack](https://jitpack.io/v/DxsSucuk/Nekos4J.svg)](https://jitpack.io/#DxsSucuk/Nekos4J)

Java API for Nekos.Life API v2

# Adding to your project

Maven:
```xml
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>

<dependency>
<groupId>pw.aru.api</groupId>
<groupId>com.github.DxsSucuk</groupId>
<artifactId>nekos4j</artifactId>
<version>VERSION</version>
<type>pom</type>
</dependency>
```
Gradle:
```gradle
compile 'pw.aru.api:nekos4j:VERSION'
repositories {
maven { url 'https://jitpack.io' }
}
compile 'com.github.DxsSucuk:VERSION'
```

You can find the latest version [here](https://bintray.com/adriantodt/maven/nekos4j)
You can find the latest version [here](https://jitpack.io/#DxsSucuk/Nekos4J)

# Usage

Expand Down
40 changes: 3 additions & 37 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ plugins {
id 'java'
id 'maven'
id 'maven-publish'
id 'com.jfrog.bintray' version '1.7.2'
}

group = 'pw.aru.api'
Expand All @@ -13,12 +12,12 @@ targetCompatibility = 1.8

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

dependencies {
//HTTP
compile 'com.github.natanbc:reliqua:2.3.2'
compile 'com.github.DxsSucuk:reliqua:2.3.2'

//JSON parser
compile 'org.json:json:20170516'
Expand All @@ -28,6 +27,7 @@ dependencies {

//Code safety
compile 'com.google.code.findbugs:jsr305:3.0.2'

}

import org.apache.tools.ant.filters.ReplaceTokens
Expand Down Expand Up @@ -81,40 +81,6 @@ artifacts {
archives javadocJar, sourcesJar
}

publishing {
publications {
BintrayRelease(MavenPublication) {
from components.java
groupId group
artifactId project.name
version project.version
artifact javadocJar
artifact sourcesJar
}
}
}

bintray {
user = bintrayUsername
key = bintrayApiKey
publications = ['BintrayRelease']
pkg {
repo = 'maven'
name = project.name
licenses = ['Apache-2.0']
vcsUrl = 'https://github.com/arubot/Nekos4J.git'
publish = true
version {
name = project.version
}
}
}

bintrayUpload {
dependsOn build
dependsOn 'publishBintrayReleasePublicationToMavenLocal'
}

static def getCommitHash() {
def p = Runtime.getRuntime().exec("git rev-parse HEAD")
p.waitFor()
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/pw/aru/api/nekos4j/image/ImageProvider.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ public interface ImageProvider {
<T> PendingRequest<T> download(Image image, InputStreamFunction<T> mapper);

/**
* Returns the Weeb4J instance associated with this object.
* Returns the Nekos4J instance associated with this object.
*
* @return The Weeb4J instance associated with this object.
* @return The Nekos4J instance associated with this object.
*/
@CheckReturnValue
@Nonnull
Expand Down