Generate Android build using VSTS pipeline

Generate Android build using VSTS pipeline

08 July 2021

With the use of VSTS pipeline you can generate Android builds easily. VSTS pipeline can pull code from any code version control tool. In this blog I am following git version control.

For creating a pipeline to generating builds you need a VSTS account. After login to the VSTS account you need to go into the pipeline menu option and follow below steps to generate Android build.

  • Click on New Pipeline button and it will ask to choose code version control as below image.
    Generate Android build using VSTS pipeline
  • I am going with the Azure Repos Git. Click on the Azure Repos Git option.
  • After this you need to choose repo and configure the repo.
  • After this step you need to configure the pipeline.
  • VSTS provides plenty of options to configure the pipeline for all types of applications.
  • I choose Android to generate builds for Android.
    Generate Android build using VSTS pipeline
  • After choosing an android template you have to do some configuration.
    Generate Android build using VSTS pipeline
  • Update the template as per your requirement.
  • workingDirectory: $(system.defaultWorkingDirectory)/AndroidApps/MyApp ($(system.defaultWorkingDirectory)) it is to fetch the default working directory.
  • gradleWrapperFile: $(system.defaultWorkingDirectory)/AndroidApps/MyApp/gradlew 
  • After these steps you need to add gradle tasks as below code snippet.
    Generate Android build using VSTS pipeline
  • Now the last step to upload the build in the artifact as below code snippet
    Generate Android build using VSTS pipeline

This whole process will pull the code from the repository and generate the build.

search
Blog Categories
Request a quote