mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-25 17:37:48 +00:00
parent
c7301a5161
commit
2360adb592
@ -66,8 +66,11 @@ public class Const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static class Url {
|
public static class Url {
|
||||||
public static final String STABLE_URL = "https://raw.githubusercontent.com/topjohnwu/magisk_files/master/stable.json";
|
private static String getRaw(String where, String name) {
|
||||||
public static final String BETA_URL = "https://raw.githubusercontent.com/topjohnwu/magisk_files/master/beta.json";
|
return String.format("https://raw.githubusercontent.com/topjohnwu/magisk_files/%s/%s", where, name);
|
||||||
|
}
|
||||||
|
public static final String STABLE_URL = getRaw("master", "stable.json");
|
||||||
|
public static final String BETA_URL = getRaw("master", "beta.json");
|
||||||
public static final String REPO_URL = "https://api.github.com/users/Magisk-Modules-Repo/repos?per_page=100&sort=pushed&page=%d";
|
public static final String REPO_URL = "https://api.github.com/users/Magisk-Modules-Repo/repos?per_page=100&sort=pushed&page=%d";
|
||||||
public static final String FILE_URL = "https://raw.githubusercontent.com/Magisk-Modules-Repo/%s/master/%s";
|
public static final String FILE_URL = "https://raw.githubusercontent.com/Magisk-Modules-Repo/%s/master/%s";
|
||||||
public static final String ZIP_URL = "https://github.com/Magisk-Modules-Repo/%s/archive/master.zip";
|
public static final String ZIP_URL = "https://github.com/Magisk-Modules-Repo/%s/archive/master.zip";
|
||||||
@ -76,7 +79,8 @@ public class Const {
|
|||||||
public static final String TWITTER_URL = "https://twitter.com/topjohnwu";
|
public static final String TWITTER_URL = "https://twitter.com/topjohnwu";
|
||||||
public static final String XDA_THREAD = "http://forum.xda-developers.com/showthread.php?t=3432382";
|
public static final String XDA_THREAD = "http://forum.xda-developers.com/showthread.php?t=3432382";
|
||||||
public static final String SOURCE_CODE_URL = "https://github.com/topjohnwu/Magisk";
|
public static final String SOURCE_CODE_URL = "https://github.com/topjohnwu/Magisk";
|
||||||
public static final String SNET_URL = "https://raw.githubusercontent.com/topjohnwu/magisk_files/b66b1a914978e5f4c4bbfd74a59f4ad371bac107/snet.apk";
|
public static final String SNET_URL = getRaw("b66b1a914978e5f4c4bbfd74a59f4ad371bac107", "snet.apk");
|
||||||
|
public static final String BOOTCTL_URL = getRaw("9c5dfc1b8245c0b5b524901ef0ff0f8335757b77", "bootctl");
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class Key {
|
public static class Key {
|
||||||
|
@ -286,7 +286,7 @@ public abstract class MagiskInstaller {
|
|||||||
|
|
||||||
protected boolean postOTA() {
|
protected boolean postOTA() {
|
||||||
SuFile bootctl = new SuFile("/data/adb/bootctl");
|
SuFile bootctl = new SuFile("/data/adb/bootctl");
|
||||||
try (InputStream in = App.self.getResources().openRawResource(R.raw.bootctl);
|
try (InputStream in = Networking.get(Const.Url.BOOTCTL_URL).execForInputStream().getResult();
|
||||||
OutputStream out = new SuFileOutputStream(bootctl)) {
|
OutputStream out = new SuFileOutputStream(bootctl)) {
|
||||||
ShellUtils.pump(in, out);
|
ShellUtils.pump(in, out);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
|
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user