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

Commit 40257b7

Browse files
authored
Merge pull request #81 from refinedmods/develop
Merge develop into main for v0.8.0 release - attempt 3
2 parents 3b2675c + de206b3 commit 40257b7

28 files changed

+787
-378
lines changed

.github/CONTRIBUTING.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Contributing to Refined Storage
2+
3+
## Versioning
4+
5+
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6+
7+
## Pull requests
8+
9+
- Keep your PR as small as possible, this makes reviewing easier.
10+
- Commits serve a clear purpose and have a fitting commit message.
11+
- Branches are kept up to date by rebasing, preferably.
12+
- PRs are merged by rebasing the commits on top of the target branch.
13+
- Changes are added in `CHANGELOG.md`. Please refrain from using technical terminology, keep it user-friendly. The
14+
format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
15+
16+
## Gitflow
17+
18+
This project uses [Gitflow](https://www.atlassian.com/git/tutorials/comparing-workflows/gitflow-workflow).
19+
20+
## Releasing
21+
22+
1) Make sure the version number in `build.gradle` is correct.
23+
2) Merge `develop` to `main`.
24+
3) Push a tag with the version number (prefixed with `v`).
25+
26+
After releasing:
27+
28+
1) Rename the "Unreleased" section to the correct version number in `CHANGELOG.md`.
29+
2) Upgrade the version number in `build.gradle`.
30+
3) Create a new "Unreleased" section in `CHANGELOG.md`.
31+
32+
## Pipelines
33+
34+
### Build
35+
36+
The build pipeline triggers when a commit is pushed to a branch or pull request.
37+
38+
### Release
39+
40+
The release pipeline triggers when a tag is pushed. This will run all the steps that our build pipeline does.
41+
42+
After that succeeds, it will publish to GitHub packages.
43+
44+
The "Unreleased" section in `CHANGELOG.md` is parsed and a GitHub release is created with the changelog body and
45+
relevant artifacts.
46+
47+
After that, a Discord and Twitter notification is sent.
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Bug report
2+
description: Found a bug or encountered a crash? Please report it here.
3+
labels: [ bug ]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
Provide a summary of the issue in the title above.
9+
- type: textarea
10+
id: description
11+
attributes:
12+
label: Describe the bug
13+
description: |
14+
Be as detailed as possible.
15+
If applicable, also tell us what you expected to happen instead.
16+
validations:
17+
required: true
18+
- type: textarea
19+
id: reproduce
20+
attributes:
21+
label: How can we reproduce this bug or crash?
22+
description: |
23+
Provide us with steps on how to reproduce this issue.
24+
Try to reproduce the issue with only Refined Storage Addons installed, if possible.
25+
placeholder: |
26+
1.
27+
2.
28+
3.
29+
validations:
30+
required: true
31+
- type: dropdown
32+
id: minecraft
33+
attributes:
34+
label: What Minecraft version is this happening on?
35+
options:
36+
- Minecraft 1.18.1
37+
- Minecraft 1.16.5
38+
- type: input
39+
id: forge
40+
attributes:
41+
label: What Forge version is this happening on?
42+
validations:
43+
required: true
44+
- type: input
45+
id: rs
46+
attributes:
47+
label: What Refined Storage Addons version is this happening on?
48+
description: |
49+
Ensure that you are running on the latest Refined Storage Addons version.
50+
validations:
51+
required: true
52+
- type: textarea
53+
id: logs
54+
attributes:
55+
label: Relevant log output
56+
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
57+
render: shell

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: true
2+
contact_links:
3+
- name: Discord Community Support
4+
url: https://discordapp.com/invite/VYzsydb
5+
about: Please ask and answer questions here. Issues should be used for bugs and feature requests.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Enhancement
2+
description: Do you have a suggestion for a new feature or a way to improve Refined Storage Addons? Let us know.
3+
labels: [ enhancement ]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
Provide a summary of the enhancement in the title above.
9+
10+
Please follow following guidelines before proposing an enchancement:
11+
1) Ensure that you are running on the latest Refined Storage Addons version (to ensure that the enhancement does not exist yet).
12+
2) Ensure that your enhancement hasn't already been posted. Please look in the closed issues as well (for enhancements that have been denied).
13+
14+
We might close your issue, without explanation, if you do not follow these guidelines.
15+
- type: textarea
16+
id: describe
17+
attributes:
18+
label: Describe your enhancement
19+
description: |
20+
Be as detailed as possible.
21+
Tell us how your idea should work. Why should we consider this?
22+
validations:
23+
required: true

.github/workflows/build.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Build
2+
on:
3+
push:
4+
pull_request:
5+
types: [ opened, synchronize, reopened ]
6+
jobs:
7+
build:
8+
strategy:
9+
matrix:
10+
java: [
11+
17
12+
]
13+
os: [ ubuntu-latest ]
14+
runs-on: ${{ matrix.os }}
15+
steps:
16+
- name: Checkout repository
17+
uses: actions/checkout@v2
18+
with:
19+
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
20+
- name: Validate Gradle wrapper
21+
uses: gradle/wrapper-validation-action@v1
22+
- name: Setup JDK ${{ matrix.java }}
23+
uses: actions/setup-java@v1
24+
with:
25+
java-version: ${{ matrix.java }}
26+
- name: Cache Gradle packages
27+
uses: actions/cache@v1
28+
with:
29+
path: ~/.gradle/caches
30+
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
31+
restore-keys: ${{ runner.os }}-gradle
32+
- name: Make Gradle wrapper executable
33+
if: ${{ runner.os != 'Windows' }}
34+
run: chmod +x ./gradlew
35+
- name: Build
36+
run: ./gradlew build
37+
env:
38+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
39+
- name: Upload build artifacts
40+
if: ${{ runner.os == 'Linux' && matrix.java == '17' }}
41+
uses: actions/upload-artifact@v2
42+
with:
43+
name: Artifacts
44+
path: build/libs/

.github/workflows/release.yml

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
name: Release
2+
on:
3+
push:
4+
tags:
5+
- "v**"
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Get tag name
11+
uses: olegtarasov/get-tag@v2.1
12+
id: tagName
13+
- name: Validate semver
14+
run: |
15+
echo $GIT_TAG_NAME | grep -oP '^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$'
16+
- name: Checkout repository
17+
uses: actions/checkout@v2
18+
- name: Validate Gradle wrapper
19+
uses: gradle/wrapper-validation-action@v1
20+
- name: Setup JDK 17
21+
uses: actions/setup-java@v1
22+
with:
23+
java-version: 17
24+
- name: Make Gradle wrapper executable
25+
if: ${{ runner.os != 'Windows' }}
26+
run: chmod +x ./gradlew
27+
- name: Build
28+
run: ./gradlew build
29+
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
RELEASE: ${{ steps.tagName.outputs.tag }}
32+
- name: Build documentation
33+
run: ./gradlew javadoc
34+
env:
35+
RELEASE: ${{ steps.tagName.outputs.tag }}
36+
- name: Publish documentation
37+
uses: JamesIves/github-pages-deploy-action@4.1.5
38+
with:
39+
branch: gh-pages
40+
folder: build/docs/javadoc
41+
- name: Publish
42+
run: ./gradlew publish
43+
env:
44+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
RELEASE: ${{ steps.tagName.outputs.tag }}
46+
- name: Retrieve changelog
47+
id: changelog_reader
48+
uses: mindsers/changelog-reader-action@v2
49+
with:
50+
version: 'Unreleased'
51+
path: ./CHANGELOG.md
52+
- name: Release on GitHub
53+
uses: softprops/action-gh-release@v1
54+
id: ghRelease
55+
with:
56+
body: ${{ steps.changelog_reader.outputs.changes }}
57+
name: ${{ steps.tagName.outputs.tag }}
58+
files: |
59+
build/libs/*.jar
60+
- name: Release on CurseForge
61+
run: ./gradlew curseforge
62+
env:
63+
RELEASE: ${{ steps.tagName.outputs.tag }}
64+
CHANGELOG: ${{ steps.changelog_reader.outputs.changes }}
65+
CURSEFORGE_TOKEN: ${{ secrets.CURSEFORGE_TOKEN }}
66+
# This is necessary because the Discord action doesn't support GH actions variable expansion?
67+
- name: Set release URL
68+
run: |
69+
echo "RELEASE_URL=${{ steps.ghRelease.outputs.url }}" >> $GITHUB_ENV
70+
- name: Notify Discord
71+
uses: Ilshidur/action-discord@0.3.2
72+
with:
73+
args: 'Refined Storage Addons {{ GIT_TAG_NAME }} has been released! {{ RELEASE_URL }}'
74+
env:
75+
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
76+
- name: Notify Twitter
77+
uses: ethomson/send-tweet-action@v1
78+
with:
79+
status: Refined Storage Addons ${{ env.GIT_TAG_NAME }} has been released! ${{ env.RELEASE_URL }}
80+
consumer-key: ${{ secrets.TWITTER_CONSUMER_API_KEY }}
81+
consumer-secret: ${{ secrets.TWITTER_CONSUMER_API_SECRET }}
82+
access-token: ${{ secrets.TWITTER_ACCESS_TOKEN }}
83+
access-token-secret: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }}

.github/workflows/unsupported.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: 'Unsupported versions'
2+
on:
3+
issues:
4+
types: [ labeled, unlabeled, reopened ]
5+
jobs:
6+
support:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: dessant/support-requests@v2
10+
with:
11+
github-token: ${{ github.token }}
12+
support-label: 'unsupported'
13+
issue-comment: >
14+
:wave: @{issue-author}, we no longer support this version of Minecraft.
15+
Please see https://refinedmods.com/refined-storage/wiki/minecraft-version-support.html
16+
close-issue: true
17+
lock-issue: false

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ run/
1313
*.iws
1414
.idea/
1515
out/
16+
logs/

0 commit comments

Comments
 (0)