2014年10月22日 星期三

Android 開發(七十一) Gradle 查詢可執行command

常常會遇到要下gradle command的時候卻不知道該怎麼去下command

例如我今天想要看 dependencies tree ,可是卻不知道該如何下commnad

gradle 有內建一個非常方便的功能

gradle -q task --all

這個commnad會將所有可執行的task 列出來,有點像是ls的感覺...

你可以利用這個command找到你希望執行的command


以下是我下 gradle -q task --all的部分可執行 command

Android tasks
-------------
actionbarsherlock:androidDependencies - Displays the Android dependencies of the project
app:androidDependencies - Displays the Android dependencies of the project
DataDroid:androidDependencies - Displays the Android dependencies of the project
FacebookSDK:androidDependencies - Displays the Android dependencies of the project
slideMenu:androidDependencies - Displays the Android dependencies of the project
viewpager:androidDependencies - Displays the Android dependencies of the project


從上面可以很清楚的知道,假設我要看我project的 dependencies
我只需要執行  gradle  app:androidDependencies 




沒有留言:

張貼留言