mirror of
https://github.com/revanced/Apktool.git
synced 2024-11-11 06:59:24 +01:00
move multi catches to multi-catch (java 7), fixed pkg id not being correctly read from apktool.yml
This commit is contained in:
parent
ed67a3d94d
commit
c6861e1241
1
CHANGES
1
CHANGES
@ -16,6 +16,7 @@ v2.0.0 (TBA)
|
|||||||
-Fixed (issue #427) - Correctly handles `--frame-path` on [b]uild
|
-Fixed (issue #427) - Correctly handles `--frame-path` on [b]uild
|
||||||
-Fixed (issue #396) - Correctly handle android:debuggable while in debug mode.
|
-Fixed (issue #396) - Correctly handle android:debuggable while in debug mode.
|
||||||
-Fixed (issue #340) - Fixed superclass errors on debug mode.
|
-Fixed (issue #340) - Fixed superclass errors on debug mode.
|
||||||
|
-Fixed (issue #458) - Fixed pkg id not being correctly set in framework files.
|
||||||
-Updated known bytes for configurations to 38 (from addition of layout direction)
|
-Updated known bytes for configurations to 38 (from addition of layout direction)
|
||||||
-Fixed NPE when handling odex apks even with --no-src specified. (Thanks Rodrigo Chiossi)
|
-Fixed NPE when handling odex apks even with --no-src specified. (Thanks Rodrigo Chiossi)
|
||||||
|
|
||||||
|
@ -268,7 +268,7 @@ public class Androlib {
|
|||||||
flags.put("compression", meta.get("compressionType") == null ? false
|
flags.put("compression", meta.get("compressionType") == null ? false
|
||||||
: (Boolean) meta.get("compressionType"));
|
: (Boolean) meta.get("compressionType"));
|
||||||
mAndRes.setSdkInfo((Map<String, String>) meta.get("sdkInfo"));
|
mAndRes.setSdkInfo((Map<String, String>) meta.get("sdkInfo"));
|
||||||
mAndRes.setPackageId((String)meta.get("packageId"));
|
mAndRes.setPackageId((Map<String, String>) meta.get("packageInfo"));
|
||||||
mAndRes.setVersionInfo((Map<String, String>) meta.get("versionInfo"));
|
mAndRes.setVersionInfo((Map<String, String>) meta.get("versionInfo"));
|
||||||
|
|
||||||
if (outFile == null) {
|
if (outFile == null) {
|
||||||
|
@ -182,19 +182,11 @@ final public class AndrolibResources {
|
|||||||
DOMSource source = new DOMSource(doc);
|
DOMSource source = new DOMSource(doc);
|
||||||
StreamResult result = new StreamResult(new File(filePath));
|
StreamResult result = new StreamResult(new File(filePath));
|
||||||
transformer.transform(source, result);
|
transformer.transform(source, result);
|
||||||
|
|
||||||
} catch (ParserConfigurationException ex) {
|
} catch (SAXException | ParserConfigurationException | IOException | TransformerException ex) {
|
||||||
throw new AndrolibException(ex);
|
throw new AndrolibException(ex);
|
||||||
} catch (SAXException ex) {
|
}
|
||||||
throw new AndrolibException(ex);
|
}
|
||||||
} catch (IOException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (TransformerConfigurationException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (TransformerException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void adjust_package_manifest(ResTable resTable, String filePath)
|
public void adjust_package_manifest(ResTable resTable, String filePath)
|
||||||
throws AndrolibException {
|
throws AndrolibException {
|
||||||
@ -233,16 +225,10 @@ final public class AndrolibResources {
|
|||||||
StreamResult result = new StreamResult(new File(filePath));
|
StreamResult result = new StreamResult(new File(filePath));
|
||||||
transformer.transform(source, result);
|
transformer.transform(source, result);
|
||||||
|
|
||||||
} catch (ParserConfigurationException ex) {
|
} catch (SAXException | ParserConfigurationException | IOException | TransformerException ex) {
|
||||||
throw new AndrolibException(ex);
|
throw new AndrolibException(ex);
|
||||||
} catch (TransformerException ex) {
|
}
|
||||||
throw new AndrolibException(ex);
|
}
|
||||||
} catch (IOException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (SAXException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void remove_manifest_versions(String filePath)
|
public void remove_manifest_versions(String filePath)
|
||||||
@ -279,15 +265,7 @@ final public class AndrolibResources {
|
|||||||
StreamResult result = new StreamResult(new File(filePath));
|
StreamResult result = new StreamResult(new File(filePath));
|
||||||
transformer.transform(source, result);
|
transformer.transform(source, result);
|
||||||
|
|
||||||
} catch (ParserConfigurationException ex) {
|
} catch (SAXException | ParserConfigurationException | IOException | TransformerException ex) {
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (SAXException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (IOException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (TransformerConfigurationException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
|
||||||
} catch (TransformerException ex) {
|
|
||||||
throw new AndrolibException(ex);
|
throw new AndrolibException(ex);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -372,8 +350,10 @@ final public class AndrolibResources {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setPackageId(String id) {
|
public void setPackageId(Map<String, String> map) {
|
||||||
mPackageId = id;
|
if (map != null) {
|
||||||
|
mPackageId = map.get("cur_package_id");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void aaptPackage(File apkFile, File manifest, File resDir,
|
public void aaptPackage(File apkFile, File manifest, File resDir,
|
||||||
@ -495,6 +475,10 @@ final public class AndrolibResources {
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
OS.exec(cmd.toArray(new String[0]));
|
OS.exec(cmd.toArray(new String[0]));
|
||||||
|
if (flags.get("verbose")) {
|
||||||
|
LOGGER.info("command ran: ");
|
||||||
|
LOGGER.info(cmd.toString());
|
||||||
|
}
|
||||||
} catch (BrutException ex) {
|
} catch (BrutException ex) {
|
||||||
throw new AndrolibException(ex);
|
throw new AndrolibException(ex);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user