diff Makefile @ 442:ced663d2e957

migrate from Eclipse to Android Studio
author Carl Byington <carl@five-ten-sg.com>
date Thu, 03 Dec 2015 12:29:29 -0800
parents d29cce60f393
children 07deaa851e7d
line wrap: on
line diff
--- a/Makefile	Thu Dec 03 12:13:52 2015 -0800
+++ b/Makefile	Thu Dec 03 12:29:29 2015 -0800
@@ -4,9 +4,6 @@
 style:=release
 dest:=/run/user/1000/gvfs/mtp*/*torage/Download
 apk:='app/build/outputs/apk/510Connectbot-$(style).apk'
-ver:=$(shell grep versionName app/src/main/AndroidManifest.xml | cut -d'"' -f2)
-id:=$(shell hg id --id)
-da:=$(shell date +%Y-%m-%d)
 version:=\
 <?xml version=\"1.0\" encoding=\"utf-8\"?>\n\
 <resources>\n\
@@ -14,9 +11,9 @@
 </resources>\n
 
 ifeq ($(style),release)
-    task=assembleRelease
+    task:=assembleRelease
 else
-	task=assembleDebug
+	task:=assembleDebug
 endif
 
 
@@ -26,6 +23,9 @@
 
 builder: prep
 	rm -rf app/build/*
+    ver:=$(shell grep versionName app/src/main/AndroidManifest.xml | cut -d'"' -f2)
+    id:=$(shell hg id --id)
+    da:=$(shell date +%Y-%m-%d)
 	echo -e "$(version)" >app/src/main/res/values/version.xml
 	cat app/src/main/res/values/version.xml
 	./gradlew $(task)