Skip to content

Commit

Permalink
Merge pull request #94 from GeorgeV220/develop
Browse files Browse the repository at this point in the history
fix(build): Fixed build warnings and errors
  • Loading branch information
GeorgeV220 authored Apr 18, 2023
2 parents 6ca2cbe + b896713 commit ab7269b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public interface ExtensionAwareness {
*/
enum Flags implements ExtensionAwareness {
/**
* This specifies that all (text) resources stored in a extension's jar
* This specifies that all (text) resources stored in an extension's jar
* use UTF-8 encoding.
*
* @deprecated all extensions are now assumed to be UTF-8 aware.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@

public final class ExtensionDescriptionFile {
private static final Pattern VALID_NAME = Pattern.compile("^[A-Za-z0-9 _.-]+$");
private static ExtensionAwareness extensionAwareness;
private static final ThreadLocal<Yaml> YAML = ThreadLocal.withInitial(() -> new Yaml(new SafeConstructor() {
{
yamlConstructors.put(null, new AbstractConstruct() {
Expand All @@ -30,7 +31,7 @@ public Object construct(@NotNull final Node node) {
if (!node.getTag().startsWith("!@")) {
return SafeConstructor.undefinedConstructor.construct(node);
}
return new ExtensionAwareness() {
return extensionAwareness = new ExtensionAwareness() {
@Override
public String toString() {
return node.toString();
Expand All @@ -49,6 +50,11 @@ public ExtensionAwareness.Flags construct(@NotNull final Node node) {
}
}
}));

public static ExtensionAwareness getAwareness() {
return extensionAwareness;
}

String rawName = null;
private String name = null;
private List<String> provides = ImmutableList.of();
Expand All @@ -72,7 +78,7 @@ public ExtensionDescriptionFile(@NotNull final InputStream stream) throws Invali
}

/**
* Loads a ExtensionDescriptionFile from the specified reader
* Loads an ExtensionDescriptionFile from the specified reader
*
* @param reader The reader
* @throws InvalidDescriptionException If the ExtensionDescriptionFile is
Expand Down
1 change: 0 additions & 1 deletion minecraft/bukkit/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,3 @@ shadowJar {

tasks.build.dependsOn(shadowJar)
tasks.publish.dependsOn(shadowJar)
tasks.shadowJar.dependsOn(jar)

0 comments on commit ab7269b

Please sign in to comment.