Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradle-命令笔记 #29

Open
jeffrey1995 opened this issue Jan 30, 2018 · 0 comments
Open

Gradle-命令笔记 #29

jeffrey1995 opened this issue Jan 30, 2018 · 0 comments

Comments

@jeffrey1995
Copy link
Owner

jeffrey1995 commented Jan 30, 2018

用来分析依赖包的结构:

apply plugin: 'project-report'

gradle htmlDependencyReport
open app/build/reports/project/dependencies/index.html

查看所有任务

./gradlew tasks --all

对某个module [moduleName] 的某个任务[TaskName] 运行

./gradlew :moduleName:taskName

查看构建版本

./gradlew -v

清除build文件夹

./gradlew clean

检查依赖并编译打包

./gradlew build

编译并安装debug包

./gradlew installDebug

编译并打印日志

./gradlew build --info

调试模式构建并打印日志

./gradlew build --info --debug --stacktrace

强制更新最新依赖,清除构建并构建

./gradlew clean --refresh-dependencies build

编译并打Debug包

./gradlew assembleDebug
./gradlew aD

编译并打Release的包

./gradlew assembleRelease
./gradlew aR

编译并打Debug包

./gradlew assembleDebug

编译app module 并打Debug包

./gradlew install app:assembleDebug

编译并打Release的包

./gradlew assembleRelease

Release模式打包并安装

./gradlew installRelease

卸载Release模式包

./gradlew uninstallRelease

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant