diff options
| author | Jules Laplace <jules@okfoc.us> | 2015-11-30 18:21:01 -0500 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2015-11-30 18:21:01 -0500 |
| commit | ded2f8928dd509acc8d4ae1e4131b622c7bb4d9c (patch) | |
| tree | a576defc78fac3b9c2c0d8a7beb18e78d6466255 /StoneIsland/plugins/phonegap-plugin-push/push.gradle | |
| parent | 60bd9bf61e4d1f3fb3925807ca754f89743cfade (diff) | |
phonegap-plugin-push
Diffstat (limited to 'StoneIsland/plugins/phonegap-plugin-push/push.gradle')
| -rw-r--r-- | StoneIsland/plugins/phonegap-plugin-push/push.gradle | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/StoneIsland/plugins/phonegap-plugin-push/push.gradle b/StoneIsland/plugins/phonegap-plugin-push/push.gradle new file mode 100644 index 00000000..d61b60f5 --- /dev/null +++ b/StoneIsland/plugins/phonegap-plugin-push/push.gradle @@ -0,0 +1,21 @@ +import java.util.regex.Pattern + +def doExtractStringFromManifest(name) { + def manifestFile = file(android.sourceSets.main.manifest.srcFile) + def pattern = Pattern.compile(name + "=\"(.*?)\"") + def matcher = pattern.matcher(manifestFile.getText()) + matcher.find() + return matcher.group(1) +} + +android { + sourceSets { + main { + manifest.srcFile 'AndroidManifest.xml' + } + } + + defaultConfig { + applicationId = doExtractStringFromManifest("package") + } +}
\ No newline at end of file |
