Changes

Jump to: navigation, search

MAP524/DPS924 Lab 1

1,020 bytes added, 14:55, 30 June 2015
Part B: Configure your environment
└── strings.xml
</pre>
<li>Finally you'll need to create a Gradle build file inside your project directory. The name of this file is "build.gradle" and it looks like this:</li>
<pre>buildscript {
repositories {
jcenter()
}
 
dependencies {
classpath 'com.android.tools.build:gradle:1.0.0'
}
}
 
apply plugin: 'com.android.application'
 
android {
compileSdkVersion 22
buildToolsVersion "22.0.1"
 
defaultConfig {
applicationId "org.hello"
minSdkVersion 15
targetSdkVersion 21
versionCode 1
versionName "1.0"
}
}</pre>
<li>You can now use Gradle to build your app. Just run this command from inside your project directory.</li>
<pre>gradle build</pre>
<li>Before you move on to PART C, try "gradle --help" to see what else gradle can do. If the build was successful you can run the Bash tree command to get a bird's eye view of what files/directories were created by the build. Save this tree output, you'll need it for PART D of this lab.</li>
</ol>

Navigation menu