Merge branch 'another-bootstrapper-fix'

This commit is contained in:
Zeruth
2019-08-02 20:03:23 -04:00
6 changed files with 88 additions and 56 deletions

View File

@@ -72,6 +72,7 @@ import net.runelite.client.ui.overlay.infobox.InfoBoxManager;
import net.runelite.client.ui.overlay.infobox.InfoBoxOverlay;
import net.runelite.client.ui.overlay.tooltip.TooltipOverlay;
import net.runelite.client.ui.overlay.worldmap.WorldMapOverlay;
import net.runelite.client.util.bootstrap.Bootstrapper;
import net.runelite.client.ws.PartyService;
import org.slf4j.LoggerFactory;
@@ -178,7 +179,8 @@ public class RuneLite
parser.accepts("developer-mode", "Enable developer tools");
parser.accepts("debug", "Show extra debugging output");
parser.accepts("no-splash", "Do not show the splash screen");
parser.accepts("bootstrap", "Builds a bootstrap with locally built jars");
parser.accepts("bootstrap-staging", "Builds a testing bootstrap with locally built jars");
final ArgumentAcceptingOptionSpec<String> proxyInfo = parser
.accepts("proxy")
.withRequiredArg().ofType(String.class);
@@ -200,6 +202,16 @@ public class RuneLite
parser.accepts("help", "Show this text").forHelp();
OptionSet options = parser.parse(args);
if (options.has("bootstrap"))
{
Bootstrapper.main(false);
System.exit(0);
}
if (options.has("bootstrap-staging"))
{
Bootstrapper.main(true);
System.exit(0);
}
if (options.has("proxy"))
{
String[] proxy = options.valueOf(proxyInfo).split(":");

View File

@@ -331,31 +331,31 @@ public class Bootstrap
artifacts[3].name = "client-" + projectVersion + ".jar";
artifacts[3].hash = getChecksumFile("./runelite-client/build/libs/" + artifacts[3].name);
artifacts[3].path = "https://raw.githubusercontent.com/runelite-extended/maven-repo/master/" + Bootstrapper.remoteLocation + artifacts[3].name;
artifacts[3].size = Long.toString(getFileSize("./runelite-client/target/" + artifacts[3].name));
artifacts[3].size = Long.toString(getFileSize("./runelite-client/build/libs/" + artifacts[3].name));
copyTodir("./runelite-client/build/libs/" + artifacts[3].name, Bootstrapper.localLocation);
artifacts[35] = new Artifact();
artifacts[35].name = "runelite-api-" + projectVersion + ".jar";
artifacts[35].hash = getChecksumFile("./runelite-api/build/libs/" + artifacts[35].name);
artifacts[35].path = "https://raw.githubusercontent.com/runelite-extended/maven-repo/master/" + Bootstrapper.remoteLocation + artifacts[35].name;
artifacts[35].size = Long.toString(getFileSize("./runelite-api/target/" + artifacts[35].name));
artifacts[35].size = Long.toString(getFileSize("./runelite-api/build/libs/" + artifacts[35].name));
copyTodir("./runelite-api/build/libs/" + artifacts[35].name, Bootstrapper.localLocation);
artifacts[36] = new Artifact();
artifacts[36].name = "runescape-api-" + projectVersion + ".jar";
artifacts[36].hash = getChecksumFile("./runescape-api/build/libs/" + artifacts[36].name);
artifacts[36].path = "https://raw.githubusercontent.com/runelite-extended/maven-repo/master/" + Bootstrapper.remoteLocation + artifacts[36].name;
artifacts[36].size = Long.toString(getFileSize("./runescape-api/target/" + artifacts[36].name));
artifacts[36].size = Long.toString(getFileSize("./runescape-api/build/libs/" + artifacts[36].name));
copyTodir("./runescape-api/build/libs/" + artifacts[36].name, Bootstrapper.localLocation);
artifacts[37] = new Artifact();
artifacts[37].name = "http-api-" + projectVersion + ".jar";
artifacts[37].hash = getChecksumFile("./http-api/build/libs/" + artifacts[37].name);
artifacts[37].path = "https://raw.githubusercontent.com/runelite-extended/maven-repo/master/" + Bootstrapper.remoteLocation + artifacts[37].name;
artifacts[37].size = Long.toString(getFileSize("./http-api/target/" + artifacts[37].name));
artifacts[37].size = Long.toString(getFileSize("./http-api/build/libs/" + artifacts[37].name));
copyTodir("./http-api/build/libs/" + artifacts[37].name, Bootstrapper.localLocation);
artifacts[47] = new Artifact();
artifacts[47].name = "injected-client-" + projectVersion + ".jar";
artifacts[47].hash = getChecksumFile("./injected-client/build/libs/" + artifacts[47].name);
artifacts[47].path = "https://raw.githubusercontent.com/runelite-extended/maven-repo/master/" + Bootstrapper.remoteLocation + artifacts[47].name;
artifacts[47].size = Long.toString(getFileSize("./http-api/target/" + artifacts[47].name));
artifacts[47].size = Long.toString(getFileSize("./injected-client/build/libs/" + artifacts[47].name));
copyTodir("./injected-client/build/libs/" + artifacts[47].name, Bootstrapper.localLocation);
}
catch (IOException | NoSuchAlgorithmException e)

View File

@@ -11,10 +11,10 @@ public class Bootstrapper
public static String remoteLocation;
public static String localLocation;
public static void main(String[] args)
public static void main(boolean staging)
{
if (args.length > 0)
if (staging)
{
remoteLocation = "staging/";
localLocation = "./staging/";

View File

@@ -8,5 +8,5 @@ public class Client
String extension = "jar";
String groupId = "net.runelite";
String properties = "";
String version = "1.5.30";
String version = "1.5.31";
}