summaryrefslogtreecommitdiff
path: root/app/build.gradle
diff options
context:
space:
mode:
authorParménides GV <parmegv@sdf.org>2015-06-05 00:02:09 +0200
committerParménides GV <parmegv@sdf.org>2015-06-05 00:02:09 +0200
commit8d39fbdb4980c95268249f21f3c6b8e36b22cf90 (patch)
tree5e54d8cc7ea06fdcf1aa88fd7fd54ec569a8b7a3 /app/build.gradle
parent8dc4f58d96892fbfd83094fb85b1d17656035290 (diff)
parent3e849c7cbe847d9260dee7a29b241c8aef185f6d (diff)
Merge branch 'feature/Update-ics-openvpn-from-GitHub-#7087' into develop
Diffstat (limited to 'app/build.gradle')
-rw-r--r--app/build.gradle71
1 files changed, 35 insertions, 36 deletions
diff --git a/app/build.gradle b/app/build.gradle
index 1d942584..0f73442c 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -1,5 +1,5 @@
apply plugin: 'android'
-//import org.ajoberstar.grgit.*
+import org.ajoberstar.grgit.Grgit
android {
compileSdkVersion 21
@@ -54,20 +54,25 @@ def processFileInplace(file, Closure processText) {
file.write(processText(text))
}
-
-task checkoutStrippedIcsOpenVPN ( type: Copy ) {
- println "checkoutStrippedIcsOpenVPN"
- //FIXME Checkout ics-openvpn-stripped from branch "ics-openvpn-upstream"
- //grgit = Grgit.open(project.file('../'))
-
- from '../../bitmask_android_tmp/ics-openvpn-stripped'
- into '../ics-openvpn-stripped'
-}
-
task copyIcsOpenVPNClasses( type: Copy ) {
println "copyIcsOpenVPNClasses"
- from ('../ics-openvpn-stripped/main/') {
- include '**/*.java'
+ from ('../ics-openvpn/main/') {
+ include '**/LaunchVPN.java'
+ include '**/OpenVPNSservice.java'
+ include '**/VpnProfile.java'
+ include '**/DisconnectVPN.java'
+ include '**/VpnProfile.java'
+ include '**/LogWindow.java'
+ include '**/LogFragment.java'
+ include '**/SeekBarTicks.java'
+ include '**/log_window.xml'
+ include '**/log_fragment.xml'
+ include '**/log_silders.xml'
+ include '**/vpnstatus.xml'
+ include '**/styles.xml'
+ include '**/dimens.xml'
+ include '**/logmenu.xml'
+ include '**/core/**.java'
includeEmptyDirs = false
@@ -85,7 +90,7 @@ task copyIcsOpenVPNClasses( type: Copy ) {
task copyIcsOpenVPNXml( type: Copy ) {
println "copyIcsOpenVPNXml"
- from ('../ics-openvpn-stripped/main/') {
+ from ('../ics-openvpn/main/') {
include '**/strings.xml'
include '**/log_*.xml'
include '**/vpnstatus.xml'
@@ -106,7 +111,7 @@ task copyIcsOpenVPNXml( type: Copy ) {
task copyIcsOpenVPNImages( type: Copy ) {
println "copyIcsOpenVPNImages"
- from ('../ics-openvpn-stripped/main/') {
+ from ('../ics-openvpn/main/') {
include '**/ic_filter*.png'
include '**/ic_delete*.png'
include '**/ic_share*.png'
@@ -118,15 +123,8 @@ task copyIcsOpenVPNImages( type: Copy ) {
} into '.'
}
-task copyIcsOpenVPNFiles( type: Copy, dependsOn: 'checkoutStrippedIcsOpenVPN' ) {
- println "copyIcsOpenVPNFiles"
- copyIcsOpenVPNClasses.execute()
- copyIcsOpenVPNXml.execute()
- copyIcsOpenVPNImages.execute()
-}
-
// thanks to http://pleac.sourceforge.net/pleac_groovy/fileaccess.html
-task removeDuplicatedStrings( dependsOn: 'copyIcsOpenVPNFiles' ) {
+task removeDuplicatedStrings() {
println "removeDuplicatedStrings"
new File('.').eachFileRecurse {
if(it.name.equals('strings.xml')) {
@@ -145,9 +143,9 @@ task removeDuplicatedStrings( dependsOn: 'copyIcsOpenVPNFiles' ) {
}
}
-task mergeUntranslatable( type: Copy, dependsOn: 'removeDuplicatedStrings') {
+task mergeUntranslatable( type: Copy ) {
println "mergeUntranslatable"
- from ('../ics-openvpn-stripped/main/') {
+ from ('../ics-openvpn/main/') {
include '**/untranslatable.xml'
rename 'untranslatable.xml', 'untranslatable-icsopenvpn.xml'
} into '.'
@@ -178,17 +176,18 @@ task mergeUntranslatable( type: Copy, dependsOn: 'removeDuplicatedStrings') {
delete ics_openvpn_untranslatable
}
-task updateIcsOpenVpn( type: Copy, dependsOn: 'mergeUntranslatable') {
- from('../ics-openvpn-stripped/') {
- include 'openvpn/**/*'
- include 'openssl/**/*'
- include 'lzo/**/**'
- include 'jni/**/*'
- include 'misc/**/*'
- include 'ovpn3/**/*'
- include 'snappy/**/*'
-
- } into './'
+task copyIcsOpenVPNFiles( type: Copy ) {
+ println "copyIcsOpenVPNFiles"
+ copyIcsOpenVPNClasses.execute()
+ copyIcsOpenVPNXml.execute()
+ copyIcsOpenVPNImages.execute()
+ //mergeUntranslatable.execute()
+ removeDuplicatedStrings.execute()
+}
+
+task updateIcsOpenVpn( type: Exec ) {
+ commandLine 'git', 'submodule', 'update', '--init', '--recursive'
+ copyIcsOpenVPNFiles.execute()
}
task buildNative ( type: Exec ) {