File tree Expand file tree Collapse file tree 3 files changed +54
-1
lines changed Expand file tree Collapse file tree 3 files changed +54
-1
lines changed Original file line number Diff line number Diff line change
1
+ name : Publish package to EternalCode Repository
2
+ on :
3
+ release :
4
+ types : [published]
5
+ jobs :
6
+ publish :
7
+ runs-on : ubuntu-latest
8
+ permissions :
9
+ contents : read
10
+ packages : write
11
+ steps :
12
+ - uses : actions/checkout@v3
13
+ - uses : actions/setup-java@v3
14
+ with :
15
+ java-version : ' 17'
16
+ distribution : ' adopt'
17
+ - name : Validate Gradle wrapper
18
+ uses : gradle/wrapper-validation-action@e6e38bacfdf1a337459f332974bb2327a31aaf4b
19
+ - name : Publish package
20
+ uses : gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1
21
+ with :
22
+ arguments : publish
23
+ env :
24
+ E_REPO_USERNAME : ${{ secrets.E_REPO_USERNAME }}
25
+ E_REPO_PASS : ${{ secrets.E_REPO_PASS }}
26
+ E_VERSION : ${{ github.ref_name }}
Original file line number Diff line number Diff line change 1
1
# EternalUpdater
2
2
✔ Updater for EternalCode plugins
3
+
4
+
5
+ # Example usage
6
+ ``` java
7
+ import com.eternalcode.eternalupdater.EternalUpdater ;
8
+
9
+ EternalUpdater eternalUpdater = new EternalUpdater (" name" , " currentPluginVer" , " githubrepo" );
10
+ RemoteInformation pluginUpdate = eternalUpdater. checkUpdates();
11
+ ```
Original file line number Diff line number Diff line change
1
+ import java.net.URI
2
+
1
3
plugins {
2
4
`java- library`
3
5
`maven- publish`
4
6
}
5
7
6
8
group = " com.eternalcode"
7
- version = " 1.0.0 "
9
+ version = System .getenv( " E_VERSION " )
8
10
9
11
repositories {
10
12
mavenCentral()
@@ -21,6 +23,22 @@ dependencies {
21
23
testRuntimeOnly(" org.junit.jupiter:junit-jupiter-engine:5.8.1" )
22
24
}
23
25
26
+ publishing {
27
+ publications {
28
+
29
+ }
30
+ repositories {
31
+ maven {
32
+ name = " eternalcode-repository"
33
+ url = URI (" https://repo.eternalcode.pl" )
34
+ credentials {
35
+ username = System .getenv(" E_REPO_USERNAME" )
36
+ password = System .getenv(" E_REPO_PASS" )
37
+ }
38
+ }
39
+ }
40
+ }
41
+
24
42
tasks.getByName<Test >(" test" ) {
25
43
useJUnitPlatform()
26
44
}
You can’t perform that action at this time.
0 commit comments