Skip to content

Commit

Permalink
Merge pull request #21 from refinedmods/release/0.3.2
Browse files Browse the repository at this point in the history
Release v0.3.2
  • Loading branch information
raoulvdberge authored Jul 26, 2024
2 parents 942f39d + 347d648 commit 28840cc
Show file tree
Hide file tree
Showing 35 changed files with 87 additions and 71 deletions.
5 changes: 3 additions & 2 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ or any other method with the owners of this repository before making a change.
These are the most important things to know before contributing (also explained in more detail later in this document):

- Commit messages must adhere to [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/).
- Branch names must be formatted correctly. The format is `{category}/GH-{issue number}/{lowercase-description}`.
- Branch names must be formatted correctly. The format is `{category}/GH-{issue number}/{lowercase-description}`. You
can also use `NO-ISSUE` instead of a GitHub issue number.
Category must match a
category [used in our Commitlint config](https://github.com/conventional-changelog/commitlint/tree/master/%40commitlint/config-conventional#type-enum).
- We use [Checkstyle](https://checkstyle.sourceforge.io/) in our build workflow to validate coding style. It is
Expand Down Expand Up @@ -47,7 +48,7 @@ Because we use merge commits when merging a PR, branch names will be part of the
branch names must follow a certain standard.

The format is `{category}/GH-{issue number}/{lowercase-description}` and a branch name can be maximum 50 characters of
length.
length. You can also use `NO-ISSUE` instead of a GitHub issue number.

Category must match a
category [used in our Commitlint config](https://github.com/conventional-changelog/commitlint/tree/master/%40commitlint/config-conventional#type-enum).
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
types: [ opened, synchronize, reopened ]
jobs:
build:
uses: refinedmods/refinedarchitect/.github/workflows/build.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/build.yml@v0.16.9
with:
mutation-testing: false
secrets: inherit
2 changes: 1 addition & 1 deletion .github/workflows/draft-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:
type: string
jobs:
draft:
uses: refinedmods/refinedarchitect/.github/workflows/draft-release.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/draft-release.yml@v0.16.9
with:
release-type: ${{ inputs.release-type }}
version-number-override: ${{ inputs.version-number-override }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/issue-for-unsupported-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ on:
types: [ labeled, unlabeled, reopened ]
jobs:
unsupported-labeler:
uses: refinedmods/refinedarchitect/.github/workflows/issue-for-unsupported-version.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/issue-for-unsupported-version.yml@v0.16.9
2 changes: 1 addition & 1 deletion .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
- closed
jobs:
publish-release:
uses: refinedmods/refinedarchitect/.github/workflows/publish-release.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/publish-release.yml@v0.16.9
secrets: inherit
with:
project-name: 'Refined Storage - JEI Integration'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/resolved-issue-locking.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ on:
- cron: '0 0 * * *'
jobs:
lock:
uses: refinedmods/refinedarchitect/.github/workflows/resolved-issue-locking.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/resolved-issue-locking.yml@v0.16.9
2 changes: 1 addition & 1 deletion .github/workflows/validate-branch-name.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ name: Validate branch name
on: [ pull_request ]
jobs:
validate-branch-name:
uses: refinedmods/refinedarchitect/.github/workflows/validate-branch-name.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/validate-branch-name.yml@v0.16.9
2 changes: 1 addition & 1 deletion .github/workflows/validate-changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ on:
types: [ opened, synchronize, reopened, ready_for_review, labeled, unlabeled ]
jobs:
validate-changelog:
uses: refinedmods/refinedarchitect/.github/workflows/validate-changelog.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/validate-changelog.yml@v0.16.9
2 changes: 1 addition & 1 deletion .github/workflows/validate-commit-messages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ name: Validate commit messages
on: [ pull_request ]
jobs:
validate-commit-messages:
uses: refinedmods/refinedarchitect/.github/workflows/validate-commit-messages.yml@v0.16.4
uses: refinedmods/refinedarchitect/.github/workflows/validate-commit-messages.yml@v0.16.9
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

## [0.3.2] - 2024-07-26

### Fixed

- Support for Refined Storage v2.0.0-milestone.4.5.

## [0.3.1] - 2024-07-10

## [0.3.0] - 2024-07-06
Expand Down Expand Up @@ -44,7 +50,9 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
- Recipe transfer integration for the Crafting Grid.
- Grid / JEI search box synchronization options.

[Unreleased]: https://github.com/refinedmods/refinedstorage-jei-integration/compare/v0.3.1...HEAD
[Unreleased]: https://github.com/refinedmods/refinedstorage-jei-integration/compare/v0.3.2...HEAD

[0.3.2]: https://github.com/refinedmods/refinedstorage-jei-integration/compare/v0.3.1...v0.3.2

[0.3.1]: https://github.com/refinedmods/refinedstorage-jei-integration/compare/v0.3.0...v0.3.1

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Refined Storage - JEI Integration [![Build Status](https://github.com/refinedmods/refinedstorage-jei-integration/actions/workflows/build.yml/badge.svg?branch=develop)](https://github.com/refinedmods/refinedstorage-jei-integration/actions/workflows/build.yml) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=refinedmods_refinedstorage-jei-integration&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=refinedmods_refinedstorage-jei-integration) [![Code Smells](https://sonarcloud.io/api/project_badges/measure?project=refinedmods_refinedstorage-jei-integration&metric=code_smells)](https://sonarcloud.io/summary/new_code?id=refinedmods_refinedstorage-jei-integration) [![Discord](https://img.shields.io/discord/342942776494653441)](https://discordapp.com/invite/VYzsydb) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE.md)
# Refined Storage - JEI Integration [![Build Status](https://github.com/refinedmods/refinedstorage-jei-integration/actions/workflows/build.yml/badge.svg?branch=develop)](https://github.com/refinedmods/refinedstorage-jei-integration/actions/workflows/build.yml) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=refinedmods_refinedstorage-jei-integration&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=refinedmods_refinedstorage-jei-integration) [![Code Smells](https://sonarcloud.io/api/project_badges/measure?project=refinedmods_refinedstorage-jei-integration&metric=code_smells)](https://sonarcloud.io/summary/new_code?id=refinedmods_refinedstorage-jei-integration) [![Crowdin](https://badges.crowdin.net/refined-storage-jei-integration/localized.svg)](https://crowdin.com/project/refined-storage-jei-integration) [![Discord](https://img.shields.io/discord/342942776494653441)](https://discordapp.com/invite/VYzsydb) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE.md)

## About

Expand Down
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
refinedstorageVersion=2.0.0-milestone.4.4
refinedarchitectVersion=0.16.9
refinedstorageVersion=2.0.0-milestone.4.5
jeiVersion=19.4.0.28
minecraftVersion=1.21
# Gradle
Expand Down
2 changes: 1 addition & 1 deletion refinedstorage-jei-integration-common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ val jeiVersion: String by project
val minecraftVersion: String by project

dependencies {
api("com.refinedmods.refinedstorage:refinedstorage-platform-common:${refinedstorageVersion}")
api("com.refinedmods.refinedstorage:refinedstorage-common:${refinedstorageVersion}")
api("mezz.jei:jei-${minecraftVersion}-common-api:${jeiVersion}")
api("mezz.jei:jei-${minecraftVersion}-common:${jeiVersion}")
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.api.PlatformApi;
import com.refinedmods.refinedstorage.common.api.RefinedStorageApi;

import net.minecraft.resources.ResourceLocation;

Expand All @@ -22,13 +22,13 @@ public static Platform getPlatform() {
return requireNonNull(platform, "Platform isn't set yet");
}

public static void init(final PlatformApi platformApi) {
platformApi.addIngredientConverter(new JeiRecipeModIngredientConverter());
platformApi.getGridSynchronizerRegistry().register(
public static void init(final RefinedStorageApi api) {
api.addIngredientConverter(new JeiRecipeModIngredientConverter());
api.getGridSynchronizerRegistry().register(
ResourceLocation.fromNamespaceAndPath(Common.MOD_ID, "jei"),
new JeiGridSynchronizer(false)
);
platformApi.getGridSynchronizerRegistry().register(
api.getGridSynchronizerRegistry().register(
ResourceLocation.fromNamespaceAndPath(Common.MOD_ID, "jei_two_way"),
new JeiGridSynchronizer(true)
);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.api.resource.list.ResourceList;
import com.refinedmods.refinedstorage.platform.common.content.Menus;
import com.refinedmods.refinedstorage.platform.common.grid.CraftingGridContainerMenu;
import com.refinedmods.refinedstorage.platform.common.support.resource.ItemResource;
import com.refinedmods.refinedstorage.common.content.Menus;
import com.refinedmods.refinedstorage.common.grid.CraftingGridContainerMenu;
import com.refinedmods.refinedstorage.common.support.resource.ItemResource;

import java.util.List;
import java.util.Optional;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.common.support.AbstractBaseScreen;
import com.refinedmods.refinedstorage.common.support.AbstractBaseScreen;

import java.util.List;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.api.PlatformApi;
import com.refinedmods.refinedstorage.platform.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.platform.common.support.AbstractBaseScreen;
import com.refinedmods.refinedstorage.platform.common.support.containermenu.AbstractResourceContainerMenu;
import com.refinedmods.refinedstorage.platform.common.support.containermenu.ResourceSlot;
import com.refinedmods.refinedstorage.platform.common.support.packet.c2s.C2SPackets;
import com.refinedmods.refinedstorage.common.api.RefinedStorageApi;
import com.refinedmods.refinedstorage.common.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.common.support.AbstractBaseScreen;
import com.refinedmods.refinedstorage.common.support.containermenu.AbstractResourceContainerMenu;
import com.refinedmods.refinedstorage.common.support.containermenu.ResourceSlot;
import com.refinedmods.refinedstorage.common.support.packet.c2s.C2SPackets;

import java.util.ArrayList;
import java.util.Collections;
Expand All @@ -31,7 +31,7 @@ private <I> List<Target<I>> getTargets(final AbstractBaseScreen screen,
final I ingredient,
final AbstractResourceContainerMenu menu) {
final List<Target<I>> targets = new ArrayList<>();
PlatformApi.INSTANCE.getIngredientConverter().convertToResource(ingredient).ifPresent(resource -> {
RefinedStorageApi.INSTANCE.getIngredientConverter().convertToResource(ingredient).ifPresent(resource -> {
for (final ResourceSlot slot : menu.getResourceSlots()) {
if (slot.isFilter() && slot.isValid(resource)) {
final Rect2i bounds = getBounds(screen, slot);
Expand Down Expand Up @@ -67,7 +67,7 @@ public Rect2i getArea() {

@Override
public void accept(final I ingredient) {
PlatformApi.INSTANCE.getIngredientConverter().convertToResource(ingredient).ifPresent(this::accept);
RefinedStorageApi.INSTANCE.getIngredientConverter().convertToResource(ingredient).ifPresent(this::accept);
}

private void accept(final PlatformResourceKey resource) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.api.PlatformApi;
import com.refinedmods.refinedstorage.platform.api.grid.view.PlatformGridResource;
import com.refinedmods.refinedstorage.platform.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.platform.common.grid.screen.AbstractGridScreen;
import com.refinedmods.refinedstorage.common.api.RefinedStorageApi;
import com.refinedmods.refinedstorage.common.api.grid.view.PlatformGridResource;
import com.refinedmods.refinedstorage.common.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.common.grid.screen.AbstractGridScreen;

import java.util.Optional;

Expand Down Expand Up @@ -34,7 +34,7 @@ public Optional<IClickableIngredient<?>> getClickableIngredientUnderMouse(
if (underlyingResource == null) {
return Optional.empty();
}
return PlatformApi.INSTANCE.getIngredientConverter().convertToIngredient(underlyingResource).flatMap(
return RefinedStorageApi.INSTANCE.getIngredientConverter().convertToIngredient(underlyingResource).flatMap(
ingredient -> convertToClickableIngredient(mouseX, mouseY, ingredient)
);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.common.grid.AbstractGridSynchronizer;
import com.refinedmods.refinedstorage.common.grid.AbstractGridSynchronizer;

import javax.annotation.Nullable;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.platform.api.support.resource.RecipeModIngredientConverter;
import com.refinedmods.refinedstorage.platform.common.support.resource.FluidResource;
import com.refinedmods.refinedstorage.platform.common.support.resource.ItemResource;
import com.refinedmods.refinedstorage.common.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.common.api.support.resource.RecipeModIngredientConverter;
import com.refinedmods.refinedstorage.common.support.resource.FluidResource;
import com.refinedmods.refinedstorage.common.support.resource.ItemResource;

import java.util.Optional;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.common.support.resource.FluidResource;
import com.refinedmods.refinedstorage.common.support.resource.FluidResource;

import java.util.Optional;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.common.grid.screen.AbstractGridScreen;
import com.refinedmods.refinedstorage.platform.common.support.AbstractBaseScreen;
import com.refinedmods.refinedstorage.common.grid.screen.AbstractGridScreen;
import com.refinedmods.refinedstorage.common.support.AbstractBaseScreen;

import javax.annotation.Nullable;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.platform.api.PlatformApi;
import com.refinedmods.refinedstorage.platform.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.platform.common.support.AbstractBaseScreen;
import com.refinedmods.refinedstorage.common.api.RefinedStorageApi;
import com.refinedmods.refinedstorage.common.api.support.resource.PlatformResourceKey;
import com.refinedmods.refinedstorage.common.support.AbstractBaseScreen;

import java.util.Optional;
import javax.annotation.Nullable;
Expand Down Expand Up @@ -33,7 +33,7 @@ public Optional<Object> convertToIngredient(@Nullable final PlatformResourceKey
if (resource == null) {
return Optional.empty();
}
return PlatformApi.INSTANCE.getIngredientConverter().convertToIngredient(resource);
return RefinedStorageApi.INSTANCE.getIngredientConverter().convertToIngredient(resource);
}

private Optional<IClickableIngredient<?>> convertToClickableIngredient(final Object ingredient) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
@ParametersAreNonnullByDefault
@FieldsAndMethodsAreNonnullByDefault
package com.refinedmods.refinedstorage.jei.common;

import com.refinedmods.refinedstorage.api.core.FieldsAndMethodsAreNonnullByDefault;

import javax.annotation.ParametersAreNonnullByDefault;
2 changes: 1 addition & 1 deletion refinedstorage-jei-integration-fabric/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ val jeiVersion: String by project
val minecraftVersion: String by project

dependencies {
modApi("com.refinedmods.refinedstorage:refinedstorage-platform-fabric:${refinedstorageVersion}")
modApi("com.refinedmods.refinedstorage:refinedstorage-fabric:${refinedstorageVersion}")
modRuntimeOnly("mezz.jei:jei-${minecraftVersion}-fabric:${jeiVersion}")
modCompileOnlyApi("mezz.jei:jei-${minecraftVersion}-common-api:${jeiVersion}")
modCompileOnlyApi("mezz.jei:jei-${minecraftVersion}-common:${jeiVersion}")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.refinedmods.refinedstorage.jei.fabric;

import com.refinedmods.refinedstorage.common.support.resource.FluidResource;
import com.refinedmods.refinedstorage.jei.common.Platform;
import com.refinedmods.refinedstorage.platform.common.support.resource.FluidResource;

import java.util.Optional;

import mezz.jei.api.fabric.ingredients.fluids.IJeiFluidIngredient;

import static com.refinedmods.refinedstorage.platform.fabric.support.resource.VariantUtil.ofFluidVariant;
import static com.refinedmods.refinedstorage.fabric.support.resource.VariantUtil.ofFluidVariant;

public class FabricPlatform implements Platform {
@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.refinedmods.refinedstorage.jei.fabric;

import com.refinedmods.refinedstorage.platform.api.PlatformApi;
import com.refinedmods.refinedstorage.platform.api.RefinedStoragePlugin;
import com.refinedmods.refinedstorage.common.api.RefinedStorageApi;
import com.refinedmods.refinedstorage.fabric.api.RefinedStoragePlugin;

import static com.refinedmods.refinedstorage.jei.common.Common.init;

public class JeiRefinedStoragePlugin implements RefinedStoragePlugin {
@Override
public void onPlatformApiAvailable(final PlatformApi platformApi) {
init(platformApi);
public void onApiAvailable(final RefinedStorageApi api) {
init(api);
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
@ParametersAreNonnullByDefault
@FieldsAndMethodsAreNonnullByDefault
package com.refinedmods.refinedstorage.jei.fabric;

import com.refinedmods.refinedstorage.api.core.FieldsAndMethodsAreNonnullByDefault;

import javax.annotation.ParametersAreNonnullByDefault;
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"fabricloader": ">=0.14.6",
"fabric-api": "*",
"minecraft": "~1.21",
"refinedstorage": ">=2.0.0-milestone.4.0",
"refinedstorage": ">=2.0.0-milestone.4.5",
"jei": ">=19",
"java": ">=17"
}
Expand Down
2 changes: 1 addition & 1 deletion refinedstorage-jei-integration-neoforge/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ val jeiVersion: String by project
val minecraftVersion: String by project

dependencies {
api("com.refinedmods.refinedstorage:refinedstorage-platform-neoforge:${refinedstorageVersion}")
api("com.refinedmods.refinedstorage:refinedstorage-neoforge:${refinedstorageVersion}")
runtimeOnly("mezz.jei:jei-${minecraftVersion}-neoforge:${jeiVersion}")
compileOnlyApi("mezz.jei:jei-${minecraftVersion}-common-api:${jeiVersion}")
compileOnlyApi("mezz.jei:jei-${minecraftVersion}-neoforge-api:${jeiVersion}")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.refinedmods.refinedstorage.jei.forge;

import com.refinedmods.refinedstorage.common.support.resource.FluidResource;
import com.refinedmods.refinedstorage.jei.common.Platform;
import com.refinedmods.refinedstorage.platform.common.support.resource.FluidResource;

import java.util.Optional;

import net.neoforged.neoforge.fluids.FluidStack;

import static com.refinedmods.refinedstorage.platform.neoforge.support.resource.VariantUtil.ofFluidStack;
import static com.refinedmods.refinedstorage.neoforge.support.resource.VariantUtil.ofFluidStack;

public class ForgePlatform implements Platform {
@Override
Expand Down
Loading

0 comments on commit 28840cc

Please sign in to comment.