-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set up basic mod class, gradle configurations, and GitHub files
- Loading branch information
bconlon
committed
Oct 12, 2022
1 parent
e838fc8
commit 0566554
Showing
4,024 changed files
with
1,036 additions
and
144,902 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
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,50 +1,98 @@ | ||
# Java Gradle CircleCI 2.0 configuration file | ||
# | ||
# Check https://circleci.com/docs/2.0/language-java/ for more details | ||
# | ||
version: 2 | ||
jobs: | ||
build: | ||
docker: | ||
# specify the version you desire here | ||
- image: cimg/openjdk:8.0.282 | ||
version: 2.1 | ||
|
||
# Specify service dependencies here if necessary | ||
# CircleCI maintains a library of pre-built images | ||
# documented at https://circleci.com/docs/2.0/circleci-images/ | ||
# - image: circleci/postgres:9.4 | ||
orbs: | ||
gradle: circleci/[email protected] | ||
|
||
working_directory: ~/repo | ||
parameters: | ||
artifact-name: | ||
type: string | ||
default: aether_ii | ||
|
||
jobs: | ||
build: | ||
machine: | ||
image: ubuntu-2204:2022.07.1 | ||
resource_class: large | ||
environment: | ||
# Customize the JVM maximum heap limit | ||
JVM_OPTS: -Xmx3200m | ||
TERM: dumb | ||
_JAVA_OPTIONS: -Xmx9600m | ||
GRADLE_OPTS: -Dorg.gradle.daemon=false | ||
steps: | ||
- setup | ||
- run: | ||
name: Remove sources before persist | ||
command: | | ||
cd ~/project/build/libs | ||
rm *-sources.jar | ||
- persist_to_workspace: | ||
root: ~/project/build/libs | ||
paths: | ||
- << pipeline.parameters.artifact-name >>-*.jar | ||
- run: | ||
name: Publish artifact link to Discord | ||
command: | | ||
artifact_path=$(curl --request GET --url https://circleci.com/api/v2/project/gh/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME/$CIRCLE_BUILD_NUM/artifacts --header 'authorization: Basic REPLACE_BASIC_AUTH' | jq -r '.items[1].path') | ||
if [ -z "${WEBHOOK_URL}" ]; then | ||
echo "NO DISCORD WEBHOOK SET" | ||
echo "Please input your DISCORD_WEBHOOK value either in the settings for this project, or as a parameter for this orb." | ||
exit 1 | ||
else | ||
curl -X POST -H 'Content-type: application/json' \ | ||
--data \ | ||
"{ \ | ||
\"embeds\": [{ \ | ||
\"title\": \"$CIRCLE_BRANCH\", \ | ||
\"description\": \"The latest CircleCI job has completed, a direct download link for the build can be found here: https://output.circle-artifacts.com/output/job/${CIRCLE_WORKFLOW_JOB_ID}/artifacts/${CIRCLE_NODE_INDEX}/${artifact_path}\", \ | ||
\"color\": \"301898\", \ | ||
\"fields\": [ \ | ||
{ \ | ||
\"name\": \"Project\", \ | ||
\"value\": \"$CIRCLE_PROJECT_REPONAME\", \ | ||
\"inline\": true \ | ||
}, \ | ||
{ \ | ||
\"name\": \"Job Number\", \ | ||
\"value\": \"$CIRCLE_BUILD_NUM\", \ | ||
\"inline\": true \ | ||
} \ | ||
] \ | ||
}] \ | ||
}" ${WEBHOOK_URL} | ||
fi | ||
publish: | ||
machine: | ||
image: ubuntu-2204:2022.07.1 | ||
resource_class: large | ||
environment: | ||
_JAVA_OPTIONS: -Xmx3200m | ||
GRADLE_OPTS: -Dorg.gradle.daemon=false | ||
steps: | ||
- checkout | ||
# Download and cache dependencies | ||
- restore_cache: | ||
keys: | ||
- v2-dependencies-{{ checksum "build.gradle" }} | ||
# fallback to using the latest cache if no exact match is found | ||
- v2-dependencies- | ||
- setup | ||
- run: gradle publish | ||
|
||
- run: git clone -b master https://github.com/Gilded-Games/OrbisLib lib/orbis-lib | ||
- run: ./gradlew -p lib/orbis-lib build | ||
commands: | ||
setup: | ||
steps: | ||
- checkout | ||
- gradle/with_cache: | ||
steps: | ||
- run: gradle build --build-cache | ||
- store_artifacts: | ||
path: ~/repo/lib/orbis-lib/build/libs/orbis-lib-1.12.2-0.2.0-SNAPSHOT-universal.jar | ||
|
||
- run: chmod +x gradlew | ||
|
||
- run: ./gradlew dependencies | ||
path: ~/project/build/libs | ||
|
||
- save_cache: | ||
paths: | ||
- ~/repo/.gradle | ||
key: v2-dependencies-{{ checksum "build.gradle" }} | ||
|
||
- run: ./gradlew test | ||
- run: ./gradlew build | ||
- store_artifacts: | ||
path: ~/repo/build/libs | ||
workflows: | ||
build: | ||
jobs: | ||
- build | ||
publish: | ||
jobs: | ||
- publish: | ||
context: | ||
- maven | ||
filters: | ||
tags: | ||
only: | ||
- /.*/ | ||
branches: | ||
ignore: | ||
- /.*/ |
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 +1,5 @@ | ||
*.webp binary | ||
# Disable autocrlf on generated files, they always generate with LF | ||
# Add any extra files or paths here to make git stop saying they | ||
# are changed when only line endings change. | ||
src/generated/**/.cache/cache text eol=lf | ||
src/generated/**/*.json text eol=lf |
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,20 @@ | ||
#!/usr/bin/env bash | ||
# Based on https://github.com/dwmkerr/java-maven-standard-version-sample/blob/master/.githooks/commit-msg | ||
|
||
# Create a regex for a conventional commit. | ||
conventional_commit_regex="^(update|feat|improv|perf|fix|refactor|style|docs|ci|build|test|chore|revert)(\([a-z \-]+\))?!?: .+$" | ||
|
||
# Get the commit message (the parameter we're given is just the path to the temporary file which holds the message). | ||
commit_message=$(cat "$1") | ||
|
||
# Check the message, if we match, all good baby. | ||
if [[ "$commit_message" =~ $conventional_commit_regex ]]; then | ||
echo -e "\e[32mCommit message meets Conventional Commit standards...\e[0m" | ||
exit 0 | ||
fi | ||
|
||
# Uh-oh, this is not a conventional commit, show an example and link to the spec. | ||
echo -e "\e[31mThe commit message does not meet the Conventional Commit standard\e[0m" | ||
echo "Examples of valid messages can be found at: https://github.com/Gilded-Games/The-Aether-II/blob/1.19/docs/references/COMMITS.md#examples" | ||
echo "More details at: https://www.conventionalcommits.org/en/v1.0.0-beta.4/" | ||
exit 1 |
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,115 @@ | ||
name: '🐛 Bug Report' | ||
description: Create an issue about a bug. | ||
labels: [ "type/bug" ] | ||
title: 'Bug: <title>' | ||
body: | ||
- type: dropdown | ||
id: feat-type | ||
attributes: | ||
label: What Feature Types Apply to This Bug? | ||
multiple: true | ||
options: | ||
- Art | ||
- Audio | ||
- Block | ||
- Config | ||
- Copy | ||
- Docs | ||
- Entity | ||
- Gui | ||
- Item | ||
- System | ||
- World-Gen | ||
- Other (Please Describe) | ||
- type: input | ||
id: other-type | ||
attributes: | ||
label: Other Type | ||
description: If you selected other in the dropdown above, please what type it is. | ||
validations: | ||
required: false | ||
- type: dropdown | ||
id: bug-type | ||
attributes: | ||
label: What Type of Bug Is This? | ||
options: | ||
- Annoyance | ||
- Compatibility | ||
- Crash | ||
- Design | ||
- Performance | ||
- Unexpected Behavior | ||
- type: input | ||
id: forge-ver | ||
attributes: | ||
label: Forge Version | ||
description: What version of Forge are you running? This can be found on the installation jar you have downloaded, in the Mod Options menu, or the profile's version. Please note "latest" is NOT a version. | ||
placeholder: "39.0.0" | ||
validations: | ||
required: true | ||
- type: input | ||
id: aether-ii-ver | ||
attributes: | ||
label: The Aether II Version | ||
description: What version of The Aether are you running? This can be found on the jar file you have downloaded or the Mod Options menu. Please note "latest" is NOT a version. | ||
placeholder: "1.1.1" | ||
validations: | ||
required: true | ||
- type: input | ||
id: mod-conflict | ||
attributes: | ||
label: Is This Bug a Conflict With Another Mod? | ||
description: If this happens due to another mod, please put the name and version of the mod here. Leave blank otherwise. | ||
validations: | ||
required: false | ||
- type: input | ||
id: client-log | ||
attributes: | ||
label: Client Log | ||
description: A **[Gist](https://gist.github.com/)** link to the full game log. This can be found in the game files under the `logs` folder. Though not necessary, a client log can help diagnose an issue better in case a bug is caused by a reported error. Provide the `latest.log` or `debug.log` file as a Gist as soon as you find the bug, as these files are reset every time the game is opened. | ||
- type: input | ||
id: crash-log | ||
attributes: | ||
label: Crash Report (if applicable) | ||
description: A **[Gist](https://gist.github.com/)** link to the crash report. This can be found in the game files under the `crash-reports` folder, and all the contents of the file should be pasted into the Gist file. If the bug does not result in a crash, ignore this field. | ||
- type: textarea | ||
id: steps | ||
attributes: | ||
label: Steps to Reproduce | ||
description: A detailed list of how you encountered this bug if it is not immediately obvious. If the bug is immediately obvious, briefly mention how to replicate it. | ||
placeholder: | | ||
How often this happens | ||
1. Step 1 | ||
2. Step 2 | ||
3. Step 3, etc. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: What You Expect To Happen | ||
description: Describe what you thought was supposed to have happened. Don't worry if you think what you expected may be wrong. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: What Actually Happened | ||
description: Describe what happened to you that wasn't to expectations. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Additional Details | ||
description: Provide any other information you think might be useful for this report. This may include screenshots, video footage, other mod details, anything you think might be relevant. | ||
- type: checkboxes | ||
id: confirmation | ||
attributes: | ||
label: Please Read and Confirm The Following | ||
options: | ||
- label: I have confirmed this bug can be replicated without the use of Optifine. | ||
required: true | ||
- label: I have confirmed this bug is on the most recently supported version of Minecraft. | ||
required: true | ||
- label: I have confirmed the details provided in this report are concise as possible and does not contained vague information (ie. Versions are properly recorded, answers to questions are clear). | ||
required: true | ||
- label: I have confirmed this issue is unique and has not been reported already. | ||
required: true |
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,15 @@ | ||
name: Add issues to project | ||
|
||
on: | ||
issues: | ||
types: | ||
- opened | ||
jobs: | ||
add-issue-to-project: | ||
name: Add issue to project | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
project-url: https://github.com/orgs/Gilded-Games/projects/5 | ||
github-token: ${{ secrets.PROJECT_ADD_TOKEN }} |
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,16 @@ | ||
name: Add pull requests to project | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
jobs: | ||
add-pull-request-to-project: | ||
name: Add pull request to project | ||
runs-on: ubuntu-latest | ||
steps: | ||
- if: github.event.pull_request.head.repo.full_name == github.repository | ||
uses: actions/[email protected] | ||
with: | ||
project-url: https://github.com/orgs/Gilded-Games/projects/5 | ||
github-token: ${{ secrets.PROJECT_ADD_TOKEN }} |
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,59 @@ | ||
name: Trigger build | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
remote_user: | ||
description: 'GitHub name of the fork organization' | ||
required: true | ||
default: 'Gilded-Games' | ||
type: string | ||
remote_name: | ||
description: 'GitHub name of the fork repository' | ||
required: true | ||
default: 'The-Aether-II' | ||
type: string | ||
remote_branch: | ||
description: 'GitHub branch that the pull request is merging from' | ||
required: true | ||
default: '1.19' | ||
type: string | ||
|
||
jobs: | ||
trigger-build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.GIT_TOKEN }} | ||
fetch-depth: 0 | ||
- name: Trigger build | ||
env: | ||
REMOTE_USER: ${{ inputs.remote_user }} | ||
REMOTE_URL: ${{ format('https://Gilded-Games-Bot:{0}@github.com/{1}/{2}', secrets.GIT_TOKEN, inputs.remote_user, inputs.remote_name) }} | ||
BRANCH: ${{ inputs.remote_branch }} | ||
REMOTE_BRANCH: ${{ format('{0}/{1}', inputs.remote_user, inputs.remote_branch) }} | ||
LOCAL_BRANCH: ${{ format('local/{0}/{1}', inputs.remote_user, inputs.remote_branch) }} | ||
MERGE_BRANCH: ${{ format('merge/{0}', inputs.remote_branch) }} | ||
run: | | ||
git config --local user.email "[email protected]" | ||
git config --local user.name "Gilded-Games-Bot" | ||
git checkout -b ${MERGE_BRANCH} ${{ github.action_ref }} | ||
git remote add ${REMOTE_USER} ${REMOTE_URL} | ||
git fetch ${REMOTE_USER} | ||
git checkout -b ${LOCAL_BRANCH} ${REMOTE_BRANCH} | ||
git checkout ${MERGE_BRANCH} | ||
git merge ${LOCAL_BRANCH} | ||
git commit --allow-empty -m "chore: Trigger build" | ||
git push --set-upstream origin ${MERGE_BRANCH} | ||
git checkout ${LOCAL_BRANCH} | ||
git merge ${MERGE_BRANCH} | ||
git push ${REMOTE_USER} HEAD:${BRANCH} | ||
sleep 60 | ||
git branch -d ${MERGE_BRANCH} | ||
git push origin --delete ${MERGE_BRANCH} |
Oops, something went wrong.