diff --git a/build/jar/apk-dependency-graph.jar b/build/jar/apk-dependency-graph.jar index 3ad77d4..a057fb9 100644 Binary files a/build/jar/apk-dependency-graph.jar and b/build/jar/apk-dependency-graph.jar differ diff --git a/release.sh b/release.sh new file mode 100644 index 0000000..ab6554d --- /dev/null +++ b/release.sh @@ -0,0 +1,8 @@ +#!/bin/bash +if [ $# -ne 1 ]; then + echo "Please, specify release version"; + exit 1; +fi +ant +echo "var dependencies = {links:[{\"source\":\"Class A\",\"dest\":\"Class B\"},{\"source\":\"Class C\",\"dest\":\"Class B\"},]};" > gui/analyzed.js +zip -u -x .DS_Store -r "apk-dependency-graph-scripts-$1.zip" build/jar/apk-dependency-graph.jar build.xml gui/* lib/* run.bat run.sh \ No newline at end of file diff --git a/src/code/SmaliAnalyzer.java b/src/code/SmaliAnalyzer.java index 1adf630..f8b1210 100644 --- a/src/code/SmaliAnalyzer.java +++ b/src/code/SmaliAnalyzer.java @@ -9,6 +9,8 @@ import java.util.HashSet; import java.util.Map; import java.util.Set; +import java.util.regex.Matcher; +import java.util.regex.Pattern; import code.io.Arguments; @@ -36,7 +38,10 @@ public boolean run() { System.err.println("Please check your filter!"); return false; } - filterAsPath = filter.replaceAll("\\.", File.separator); + + String replacement = Matcher.quoteReplacement(File.separator); + String searchString = Pattern.quote("."); + filterAsPath = filter.replaceAll(searchString, replacement); File projectFolder = getProjectFolder(); if (projectFolder.exists()) { traverseSmaliCode(projectFolder);