-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4a95774
commit 4e8cd10
Showing
48 changed files
with
706 additions
and
475 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,40 @@ | ||
version: 2 | ||
registries: | ||
maven-central: | ||
type: maven-repository | ||
url: https://repo.maven.apache.org/maven2/ | ||
fabricmc: | ||
type: maven-repository | ||
url: https://maven.fabricmc.net/ | ||
quiltmc: | ||
type: maven-repository | ||
url: https://maven.quiltmc.org/repository/release/ | ||
parchment: | ||
type: maven-repository | ||
url: https://maven.parchmentmc.org/ | ||
neoforge: | ||
type: maven-repository | ||
url: https://maven.neoforged.net/ | ||
maven-central: | ||
type: maven-repository | ||
url: https://repo.maven.apache.org/maven2/ | ||
fabricmc: | ||
type: maven-repository | ||
url: https://maven.fabricmc.net/ | ||
quiltmc: | ||
type: maven-repository | ||
url: https://maven.quiltmc.org/repository/release/ | ||
parchment: | ||
type: maven-repository | ||
url: https://maven.parchmentmc.org/ | ||
neoforged: | ||
type: maven-repository | ||
url: https://maven.neoforged.net/ | ||
lukebemish: | ||
type: maven-repository | ||
url: https://maven.lukebemish.dev/ | ||
architectury: | ||
type: maven-repository | ||
url: https://maven.architectury.dev/ | ||
updates: | ||
- package-ecosystem: "gradle" | ||
directory: "/" | ||
registries: | ||
- maven-central | ||
- fabricmc | ||
- quiltmc | ||
- parchment | ||
- neoforge | ||
schedule: | ||
interval: "weekly" | ||
ignore: | ||
- dependency-name: "*modsdotgroovy*" | ||
update-types: ["version-update:semver-major"] | ||
- dependency-name: "com.mojang:minecraft" | ||
update-types: ["version-update:semver-major"] | ||
- dependency-name: "*neoforge*" | ||
update-types: ["version-update:semver-major"] | ||
- dependency-name: "org.quiltmc*" | ||
update-types: ["version-update:semver-major"] | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "weekly" | ||
- package-ecosystem: "gradle" | ||
directory: "/" | ||
registries: | ||
- maven-central | ||
- fabricmc | ||
- quiltmc | ||
- parchment | ||
- neoforged | ||
- lukebemish | ||
- architectury | ||
schedule: | ||
interval: "weekly" | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "weekly" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
{ | ||
"jobs": { | ||
"build": { | ||
"runs-on": "ubuntu-22.04", | ||
"steps": [ | ||
{ | ||
"name": "Setup Java", | ||
"run": "echo \"JAVA_HOME=$JAVA_HOME_17_X64\" >> \"$GITHUB_ENV\"" | ||
}, | ||
{ | ||
"with": { | ||
"fetch-depth": "0", | ||
"persist-credentials": "false" | ||
}, | ||
"name": "Checkout", | ||
"uses": "actions/checkout@v4" | ||
}, | ||
{ | ||
"with": { | ||
"path": "**/.gradle/loom-cache", | ||
"key": "${{ runner.os }}-gradle-${{ hashFiles('**/libs.versions.*', '**/*.gradle*', '**/gradle-wrapper.properties') }}", | ||
"restore-keys": "${{ runner.os }}-gradle-" | ||
}, | ||
"name": "Cache", | ||
"uses": "actions/cache/restore@v3" | ||
}, | ||
{ | ||
"with": { | ||
"cache-read-only": true, | ||
"gradle-home-cache-cleanup": true | ||
}, | ||
"name": "Setup Gradle", | ||
"uses": "gradle/gradle-build-action@v2" | ||
}, | ||
{ | ||
"name": "Build", | ||
"run": "./gradlew checkLicenses build", | ||
"id": "build", | ||
"env": { | ||
"PR_NUMBER": "${{ github.event.pull_request.number }}" | ||
} | ||
}, | ||
{ | ||
"name": "Publish", | ||
"run": "./gradlew publish", | ||
"id": "publish", | ||
"env": { | ||
"PR_NUMBER": "${{ github.event.pull_request.number }}" | ||
} | ||
}, | ||
{ | ||
"with": { | ||
"name": "artifacts", | ||
"path": "build/repo" | ||
}, | ||
"name": "Archive Publishable Artifacts", | ||
"uses": "actions/upload-artifact@v4" | ||
} | ||
] | ||
} | ||
}, | ||
"name": "Build PR", | ||
"concurrency": "ci-${{ github.ref }}", | ||
"on": { | ||
"pull_request": { | ||
|
||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
{ | ||
"jobs": { | ||
"publish": { | ||
"runs-on": "ubuntu-22.04", | ||
"steps": [ | ||
{ | ||
"with": { | ||
"repository": "lukebemish/artifact-sync", | ||
"ref": "refs/heads/main", | ||
"persist-credentials": false | ||
}, | ||
"name": "Checkout Artifact Sync", | ||
"uses": "actions/checkout@v4" | ||
}, | ||
{ | ||
"run": "mkdir repo" | ||
}, | ||
{ | ||
"with": { | ||
"script": "const pull_requests = ${{ toJSON(github.event.workflow_run.pull_requests) }};\nif (!pull_requests.length) {\n return core.error(\"This workflow doesn't match any pull requests!\");\n}\nlet allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({\n owner: context.repo.owner,\n repo: context.repo.repo,\n run_id: context.payload.workflow_run.id,\n});\nlet matchArtifact = allArtifacts.data.artifacts.filter((artifact) => {\n return artifact.name == \"artifacts\"\n})[0];\nlet download = await github.rest.actions.downloadArtifact({\n owner: context.repo.owner,\n repo: context.repo.repo,\n artifact_id: matchArtifact.id,\n archive_format: 'zip',\n});\nlet fs = require('fs');\nfs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/repo.zip`, Buffer.from(download.data));" | ||
}, | ||
"name": "Download Artifacts", | ||
"uses": "actions/github-script@v7" | ||
}, | ||
{ | ||
"name": "Unpack Artifacts", | ||
"run": "unzip repo.zip -d repo" | ||
}, | ||
{ | ||
"name": "Publish Artifacts", | ||
"run": "python3 run.py", | ||
"env": { | ||
"MAVEN_USER": "github", | ||
"MAVEN_PASSWORD": "${{ secrets.PR_MAVEN_PASSWORD }}", | ||
"MAVEN_URL": "https://maven.lukebemish.dev/pullrequests/", | ||
"ALLOWED_VERSION": "*-pr${{ github.event.workflow_run.pull_requests[0].number }}", | ||
"ALLOWED_PATHS": "dev/lukebemish/dynamicassetgenerator/dynamicassetgenerator-*" | ||
} | ||
} | ||
], | ||
"if": "${{ github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success' }}" | ||
} | ||
}, | ||
"name": "Publish PR", | ||
"concurrency": "ci-${{ github.ref }}", | ||
"on": { | ||
"workflow_run": { | ||
"types": [ | ||
"completed" | ||
], | ||
"workflows": [ | ||
"Build PR" | ||
] | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,88 @@ | ||
name: Release | ||
concurrency: ci-${{ github.ref }} | ||
on: | ||
workflow_dispatch: | ||
jobs: | ||
build: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Setup Java | ||
run: | | ||
echo "JAVA_HOME=$JAVA_HOME_17_X64" >> "$GITHUB_ENV" | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- uses: fregante/setup-git-user@v2 | ||
- uses: actions/cache@v3 | ||
with: | ||
path: | | ||
.gradle/quilt-loom-cache | ||
.gradle/loom-cache | ||
**/.gradle/caches | ||
**/.gradle/repositories | ||
**/build/neoForm | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/libs.versions.*', '**/*.gradle*', '**/gradle-wrapper.properties') }} | ||
restore-keys: ${{ runner.os }}-gradle- | ||
- uses: gradle/gradle-build-action@v2 | ||
name: Setup Gradle | ||
- name: Tag Release | ||
run: | | ||
./gradlew tagRelease | ||
- name: Build | ||
run: | | ||
./gradlew checkLicenses build | ||
- name: Publish | ||
run: | | ||
./gradlew publish | ||
env: | ||
MAVEN_USER: github | ||
MAVEN_PASSWORD: ${{ secrets.RELEASE_MAVEN_PASSWORD }} | ||
MAVEN_URL: https://maven.lukebemish.dev/releases/ | ||
- run: | | ||
git push | ||
git push --tags | ||
{ | ||
"jobs": { | ||
"build": { | ||
"runs-on": "ubuntu-22.04", | ||
"permissions": { | ||
"contents": "write" | ||
}, | ||
"steps": [ | ||
{ | ||
"name": "Setup Java", | ||
"run": "echo \"JAVA_HOME=$JAVA_HOME_17_X64\" >> \"$GITHUB_ENV\"" | ||
}, | ||
{ | ||
"with": { | ||
"fetch-depth": "0" | ||
}, | ||
"name": "Checkout", | ||
"uses": "actions/checkout@v4" | ||
}, | ||
{ | ||
"with": { | ||
"path": "**/.gradle/loom-cache", | ||
"key": "${{ runner.os }}-gradle-${{ hashFiles('**/libs.versions.*', '**/*.gradle*', '**/gradle-wrapper.properties') }}", | ||
"restore-keys": "${{ runner.os }}-gradle-" | ||
}, | ||
"name": "Cache", | ||
"uses": "actions/cache@v3" | ||
}, | ||
{ | ||
"with": { | ||
"gradle-home-cache-cleanup": true | ||
}, | ||
"name": "Setup Gradle", | ||
"uses": "gradle/gradle-build-action@v2" | ||
}, | ||
{ | ||
"uses": "fregante/setup-git-user@v2" | ||
}, | ||
{ | ||
"name": "Tag Release", | ||
"run": "./gradlew tagRelease", | ||
"id": "tag_release", | ||
"env": { | ||
"RELEASE_MAVEN_PASSWORD": "${{ secrets.RELEASE_MAVEN_PASSWORD }}", | ||
"RELEASE_MAVEN_USER": "github", | ||
"RELEASE_MAVEN_URL": "https://maven.lukebemish.dev/releases/", | ||
"CURSEFORGE_KEY": "${{ secrets.CURSEFORGE_KEY }}", | ||
"MODRINTH_KEY": "${{ secrets.MODRINTH_KEY }}" | ||
} | ||
}, | ||
{ | ||
"name": "Build", | ||
"run": "./gradlew checkLicenses build", | ||
"id": "build", | ||
"env": { | ||
"RELEASE_MAVEN_PASSWORD": "${{ secrets.RELEASE_MAVEN_PASSWORD }}", | ||
"RELEASE_MAVEN_USER": "github", | ||
"RELEASE_MAVEN_URL": "https://maven.lukebemish.dev/releases/", | ||
"CURSEFORGE_KEY": "${{ secrets.CURSEFORGE_KEY }}", | ||
"MODRINTH_KEY": "${{ secrets.MODRINTH_KEY }}" | ||
} | ||
}, | ||
{ | ||
"run": "git push && git push --tags" | ||
}, | ||
{ | ||
"name": "Publish", | ||
"run": "./gradlew publish", | ||
"id": "publish", | ||
"env": { | ||
"RELEASE_MAVEN_PASSWORD": "${{ secrets.RELEASE_MAVEN_PASSWORD }}", | ||
"RELEASE_MAVEN_USER": "github", | ||
"RELEASE_MAVEN_URL": "https://maven.lukebemish.dev/releases/", | ||
"CURSEFORGE_KEY": "${{ secrets.CURSEFORGE_KEY }}", | ||
"MODRINTH_KEY": "${{ secrets.MODRINTH_KEY }}" | ||
} | ||
} | ||
] | ||
} | ||
}, | ||
"name": "Release", | ||
"concurrency": "ci-${{ github.ref }}", | ||
"on": { | ||
"workflow_dispatch": { | ||
|
||
} | ||
} | ||
} |
Oops, something went wrong.