mirror of
https://github.com/runelite/plugin-hub.git
synced 2026-05-15 03:15:20 -04:00
package: Add warning field to plugin manifest (#159)
This commit is contained in:
@@ -42,7 +42,7 @@ for PLUGINFILE in plugins/*; do
|
||||
disabled=
|
||||
# shellcheck disable=SC2162
|
||||
while read LINE || [[ -n "$LINE" ]]; do
|
||||
[[ $LINE =~ ^(repository|commit|disabled)=(.*)$ ]]
|
||||
[[ $LINE =~ ^(repository|commit|disabled|warning)=(.*)$ ]]
|
||||
eval "${BASH_REMATCH[1]}=\"${BASH_REMATCH[2]}\""
|
||||
done < "$PLUGINFILE"
|
||||
[ -z "$disabled" ] || continue
|
||||
|
||||
@@ -42,7 +42,7 @@ RUNELITE_VERSION="$(cat "$SCRIPT_HOME/runelite.version")"
|
||||
disabled=
|
||||
# shellcheck disable=SC2162
|
||||
while read LINE || [[ -n "$LINE" ]]; do
|
||||
[[ $LINE =~ ^(repository|commit|disabled)=(.*)$ ]]
|
||||
[[ $LINE =~ ^(repository|commit|disabled|warning)=(.*)$ ]]
|
||||
eval "${BASH_REMATCH[1]}=\"${BASH_REMATCH[2]}\""
|
||||
done < "$PLUGINFILE"
|
||||
[ -z "$disabled" ] || exit 0
|
||||
@@ -81,6 +81,7 @@ SIGNING_KEY="" REPO_CREDS="" gradle \
|
||||
-DrlpluginOutputDirectory="$BUILDDIR" \
|
||||
-DrlpluginPluginID="$PLUGIN_ID" \
|
||||
-DrlpluginCommit="$commit" \
|
||||
-DrlpluginWarning="$warning" \
|
||||
rlpluginPackageJar rlpluginEmitManifest
|
||||
|
||||
[ -s "$BUILDDIR/plugin.jar" ]
|
||||
|
||||
@@ -68,6 +68,9 @@ allprojects {
|
||||
def manifest = new ExternalPluginManifest()
|
||||
manifest.internalName = System.properties["rlpluginPluginID"]
|
||||
manifest.commit = System.properties["rlpluginCommit"]
|
||||
if (System.properties["rlpluginWarning"]) {
|
||||
manifest.warning = System.properties["rlpluginWarning"];
|
||||
}
|
||||
|
||||
def pluginJar = new File(System.properties["rlpluginOutputDirectory"], "plugin.jar");
|
||||
manifest.hash = Files.asByteSource(pluginJar)
|
||||
@@ -147,6 +150,7 @@ class ExternalPluginManifest {
|
||||
String version;
|
||||
String author;
|
||||
String description;
|
||||
String warning;
|
||||
String[] tags;
|
||||
URL support;
|
||||
boolean hasIcon;
|
||||
|
||||
Reference in New Issue
Block a user