Last Update October 31, 2020: We improved the overall article.
1 . Open Tools > Open Terminal….
2 .Navigate to the tools/ directory of your SDK and run
3. To see a list of available targets and their corresponding IDs, execute: android list targets.
Managing Projects from the Command Line