Android Gradle
Build system, dependencies, build types, flavors, signing
1What is Gradle in Android?
What is Gradle in Android?
답변
Gradle is Android's official build system. It automates code compilation, dependency management, packaging into APK/AAB, signing, and running tests. Gradle uses scripts (build.gradle) written in Groovy or Kotlin DSL. It's a flexible and powerful tool that replaces older systems like Ant or Maven.
2What's the difference between build.gradle (Project) and build.gradle (Module: app)?
What's the difference between build.gradle (Project) and build.gradle (Module: app)?
답변
build.gradle (Project): GLOBAL configuration for all project modules. Defines repositories (Maven, Google), Android Gradle plugin versions, common dependencies. build.gradle (Module: app): SPECIFIC configuration for app module. Defines applicationId, versionCode, minSdk, targetSdk, module dependencies. A project can have multiple modules, each with its build.gradle.
3What is applicationId in Android?
What is applicationId in Android?
답변
applicationId is the UNIQUE identifier of the app on Google Play Store and on device. Format: com.company.appname. Two apps with same applicationId cannot coexist. applicationId is defined in build.gradle: android { defaultConfig { applicationId 'com.example.app' } }. Don't confuse with code package name (can be different).
What's the difference between versionCode and versionName?
What is minSdk in Android?
+23 면접 질문