Skip to content

Use jitpack for the dependencies #3

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

Open
wants to merge 1 commit 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
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@

You can use this repository as base for your external plugins, and host it on GitHub to make your external plugins available for everybody through the external manager plugin panel in the OpenOSRS client.

First of all you need to build the client (refer to the steps in this [guide][1])
After building you need to upload all the artifacts to your local maven repository.
You can do this within intellij by going to the gradle panel at the right hand side and click on OpenOSRS -> Tasks -> publishing -> publishToMavenLocal
This pulls down the latest snapshot for OpenOSRS, which is hosted through [jitpack.io](https://jitpack.io). This means you don't need to maintain that locally. This will be changed to an actual version when versioning actually works with OpenOSRS and Jitpack.

In this repository you'll find two examples one is written in kotlin and the other one is written in java.
Before you start you need to make a couple changes:
Expand Down
10 changes: 9 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ project.extra["GithubUrl"] = "http://github.com/<INSERT NAME>/<INSERT REPOSITORY

apply<BootstrapPlugin>()

allprojects {
repositories {
maven { url = uri("https://jitpack.io") }
}
}

subprojects {
group = "com.example"

Expand All @@ -28,7 +34,9 @@ subprojects {

exclusiveContent {
forRepository {
mavenLocal()
maven {
url = uri("https://jitpack.io")
}
}
filter {
includeGroupByRegex("com\\.openosrs.*")
Expand Down
1 change: 0 additions & 1 deletion buildSrc/src/main/kotlin/Dependencies.kt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
*/

object ProjectVersions {
const val openosrsVersion = "3.0.7"
const val apiVersion = "0.0.1"
}

Expand Down
6 changes: 2 additions & 4 deletions javaexample/javaexample.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import ProjectVersions.openosrsVersion

/*
* Copyright (c) 2019 Owain van Brakel <https://github.com/Owain94>
* All rights reserved.
Expand Down Expand Up @@ -34,8 +32,8 @@ dependencies {
annotationProcessor(Libraries.lombok)
annotationProcessor(Libraries.pf4j)

compileOnly("com.openosrs:runelite-api:$openosrsVersion+")
compileOnly("com.openosrs:runelite-client:$openosrsVersion+")
implementation("com.github.open-osrs.runelite:runelite-api:-SNAPSHOT")
implementation("com.github.open-osrs.runelite:runelite-client:-SNAPSHOT")

compileOnly(Libraries.guice)
compileOnly(Libraries.javax)
Expand Down
6 changes: 2 additions & 4 deletions kotlinexample/kotlinexample.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import ProjectVersions.openosrsVersion

/*
* Copyright (c) 2019 Owain van Brakel <https://github.com/Owain94>
* All rights reserved.
Expand Down Expand Up @@ -40,8 +38,8 @@ dependencies {

kapt(Libraries.pf4j)

compileOnly("com.openosrs:runelite-api:$openosrsVersion+")
compileOnly("com.openosrs:runelite-client:$openosrsVersion+")
implementation("com.github.open-osrs.runelite:runelite-api:-SNAPSHOT")
implementation("com.github.open-osrs.runelite:runelite-client:-SNAPSHOT")

compileOnly(Libraries.guice)
compileOnly(Libraries.javax)
Expand Down