6. Really ?
•
Don’t have to buy a Mac
... you’ll buy one eventually (look at me)
•
There’s an emulator
... you really use it ?
•
Android phone is way cheaper than iPhone !
... you mean those in the next page ?
13. It’s a bird.. It’s a plane..
It’s Genymotion !
http:/
/www.genymotion.com
14. Is it the one ?
•
•
•
•
Android x86 emulator based on AndroVM open
source project
•
http:/
/androvm.org/
(In some case) faster than SDK emulator
Multi-platform
IDE plugins
15. Good for ..
•
•
Test applications
•
Fast & cable free
Screencast
•
Use your favorite software (for me:
QuickTime for OS X)
16. And gamers love it ..
https://www.google.com.tw/search?q=神魔之塔+genymotion
24. Launch from CLI
•
•
VBoxManage list vms
•
"Galaxy Nexus - 4.2.2 - with Google Apps - API 17 720x1280" {fbbd7f3e-188d-4a9b-8cdc-5b70c1554f5b}
player --vm-name <VM name/id>
•
/Application/Genymotion.app/Contents/MacOS/player --vm-name "Galaxy
Nexus - 4.2.2 - with Google Apps - API 17 - 720x1280"
25. genyshell
•
Example: Setup gps to somewhere in Taipei
•
•
Content of file “gps_loc”
•
•
•
gps setstatus enabled
gps setlatitude 25.03
gps setlongitude 121.54
Command to apply configurations
•
genyshell -f gps_loc
26. Change resolution
•
•
•
Dummy way: Set in menu before launch
Geek way: Set through adb
•
•
•
adb shell am display-size 800x480
adb shell am display-density 240
adb shell am display-size reset
For 4.3+
•
•
adb shell wm size 800x480
adb shell wm density 240
29. What is gradle ?
Gradle is build automation evolved. Gradle can automate the building,
testing, publishing, deployment and more of software packages or
other types of projects such as generated static websites, generated
documentation or indeed anything else.
!
Gradle combines the power and flexibility of Ant with the dependency
management and conventions of Maven into a more effective way to
build. Powered by a Groovy DSL and packed with innovation, Gradle
provides a declarative way to describe all kinds of builds through
sensible defaults. Gradle is quickly becoming the build system of
choice for many open source projects, leading edge enterprises and
legacy automation challenges.
- http:/
/www.gradle.org/
30. .. short version
An open source build system that combines the
power of Ant & Maven but easy to use
31. Why (google wants to change the
build system to) gradle ?
•
My guess..
•
•
Simplify and unify project dependency
management in IDE & CLI
•
Think about Eclipse & ant (ci server)
BETA
Android Studio is coming !
32. Should I use it ?
•
•
•
For small project
•
Easy to convert
For large project
•
Worth trying if it can simplify the configurations
(dependency)
For project with variants
•
Time for better management tool
33. Will it blow up my
projects ?
It’s 2013 now, you should have SCM … right ?
50. Happy building
•
Put build.gradle & settings.gradle in app
project directory
•
•
Put build.gradle in library project directory
Build: gradle assemble
•
build/apk/
65. Product flavor
•
•
Defines a customised version of application
build by the project
•
•
Free / Paid
Amazon / Play Store / blah store
Same type as defaultConfig
76. Why & How ?
•
•
Time is money
Use aar instead of re-compiling everything
•
aar: Binary distribution of an Android Library
Project
•
http:/
/tools.android.com/tech-docs/newbuild-system/aar-format
96. For other issues ..
•
•
Google Maps Android API v2 gradle integration
•
•
Different resources for build types
http:/
/23pin.logdown.com/posts/144771-googlemaps-android-api-v2-gradle-integration
Gradle and GCM project integration
•
•
Difference in AndroidManifest.xml
http:/
/23pin.logdown.com/posts/144770-gradle-andgcm-project-integration