We have some CI hosts without X-Window installed, i know how to update SDK with android update command, but how can i update platform-tools with this command?
Open the Preferences window by clicking File > Settings (on Mac, Android Studio > Preferences). In the left panel, click Appearance & Behavior > System Settings > Updates. Be sure that Automatically check for updates is checked, then select a channel from the drop-down list (see figure 1). Click Apply or OK.
Android SDK Build-Tools is a component of the Android SDK required for building Android apps. It's installed in the <sdk>/build-tools/ directory.
You can use the following commands:
$ android list sdk
$ android update sdk --no-ui --filter 1,platform-tools
The first command lists the available packages that are still to be installed (indexed by number), as for example:
Packages available for installation or update: 9
1- Android SDK Tools, revision 19
2- Android SDK Platform-tools, revision 11
...
According to that list you can issue the second command to install the packages that you want to install.
The --filter
option limits the update to the packages that you want to install. You specify those packages in a comma-separated format. Also, you can filter them by the index number provided in the listing resulting from the first command.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With