Skip to content
This repository was archived by the owner on Mar 9, 2025. It is now read-only.

Commit 7ba331e

Browse files
committed
GitHubPackages
1 parent c4f8a8b commit 7ba331e

File tree

3 files changed

+32
-1
lines changed

3 files changed

+32
-1
lines changed

.github/workflows/publish.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Publish package to GitHub Packages
2+
on:
3+
release:
4+
types: [created]
5+
jobs:
6+
publish:
7+
runs-on: ubuntu-latest
8+
permissions:
9+
contents: read
10+
packages: write
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: actions/setup-java@v4
14+
with:
15+
java-version: '21'
16+
distribution: 'temurin'
17+
- name: Setup Gradle
18+
uses: gradle/actions/setup-gradle@v4
19+
20+
- name: Publish package
21+
run: ./gradlew publish
22+
env:
23+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

build.gradle

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,5 +74,13 @@ publishing {
7474
// Notice: This block does NOT have the same function as the block in the top level.
7575
// The repositories here will be used for publishing your artifact, not for
7676
// retrieving dependencies.
77+
maven {
78+
name = "GitHubPackages"
79+
url = "https://maven.pkg.github.com/TexBlock/FoxifiedNetworking"
80+
credentials {
81+
username = 'TexBlock'
82+
password = project.findProperty("gpr.key") ?: System.getenv("GITHUB_TOKEN")
83+
}
84+
}
7785
}
7886
}

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ org.gradle.jvmargs=-Xmx1G
33
loom.platform = neoforge
44

55
# Mod properties
6-
mod_version = 0.1.0-alpha1
6+
mod_version = 0.1.0-alpha2
77
maven_group = me.textrue.foxified_networking
88
archives_name = FoxifiedNetworkingAPI
99

0 commit comments

Comments
 (0)