Skip to content

November 27, 2011

Managing android virtual machines the CLI way

In a previous post, I were explaining how to generate android packages using a script I made.

I’ve recently upgraded that script so that we don’t have to create any virtual machines, if there is not a virtual machine with the name of the pacakge we’re doing, It’ll automagically create one!

It’s basically using “android” tool from android sdk, with the avd parameters, wich are:

  • list avd : Lists existing Android Virtual Devices.
  • create avd: Creates a new Android Virtual Device.
  • move avd: Moves or renames an Android Virtual Device.
  • delete avd: Deletes an Android Virtual Device.
  • update avd: Updates an Android Virtual Device to match the folders

We’re checking if the AVD exists already

android avd list | grep $package

And if not, we create the package:

android avd create -t 1 --name $package

You can get the script, as always, at my github

Read more from Life

Share your thoughts, post a comment.

(required)
(required)

Note: HTML is allowed. Your email address will never be published.

Subscribe to comments