Skip to content

Commit d4884ef

Browse files
authored
Merge pull request #859 from plopez01/maven-corelib-docs
Update core/README.md on how to use the core library from Maven Central.
2 parents e631383 + 442d0e1 commit d4884ef

File tree

1 file changed

+62
-0
lines changed

1 file changed

+62
-0
lines changed

core/README.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,65 @@
1+
# Including the Processing Core library on your project
2+
Processing’s core libraries are available through [Maven Central](https://central.sonatype.com/artifact/org.processing/core).
3+
This allows integration of Processing into Java-based projects using build tools like Maven or Gradle.
4+
5+
> [!IMPORTANT]
6+
> Repository https://jogamp.org/deployment/maven must be added to the repository list.
7+
>
8+
> This is because the core library depends on some external libraries that are hosted on the aftermentioned repository.
9+
> See the [Examples](#Examples) section on how to do this.
10+
11+
## Examples
12+
Here are some examples on how to add the Processing core library to the Maven and Gradle build systems.
13+
All examples consist on two parts:
14+
1. Adds the https://jogamp.org/deployment/maven repository to the build system to satisfy dependencies needed by the Processing core library.
15+
2. Adds the Processing core library as a dependency to your project.
16+
### Maven
17+
```xml
18+
<repositories>
19+
<repository>
20+
<id>jogamp</id>
21+
<url>https://jogamp.org/deployment/maven</url>
22+
</repository>
23+
</repositories>
24+
25+
<dependencies>
26+
<dependency>
27+
<groupId>org.processing</groupId>
28+
<artifactId>core</artifactId>
29+
<version>4.3.1</version>
30+
</dependency>
31+
</dependencies>
32+
```
33+
### Gradle (kotlin)
34+
```gradle
35+
repositories {
36+
mavenCentral()
37+
maven {
38+
url = uri("https://jogamp.org/deployment/maven")
39+
}
40+
}
41+
42+
dependencies {
43+
implementation("org.processing:core:4.3.1")
44+
}
45+
```
46+
### Gradle (groovy)
47+
```gradle
48+
repositories {
49+
mavenCentral()
50+
maven {
51+
url = uri("https://jogamp.org/deployment/maven")
52+
}
53+
}
54+
55+
dependencies {
56+
implementation group: 'org.processing', name: 'core', version: '4.3.1'
57+
}
58+
```
59+
### Other
60+
Other example snippets on including the library are included in the [Maven Central repo](https://central.sonatype.com/artifact/org.processing/core).
61+
Please look up on how to add the custom https://jogamp.org/deployment/maven repository to your build system.
62+
163
## There are significant changes to `core` in Processing 3.
264

365

0 commit comments

Comments
 (0)