Ivan B
Ivan B

Reputation: 414

Configure jenkins with different build tupes

I have a question about configuring jenkins.

I have two build types in my build gradle file for my android project. Release and debug.

I want configure jenkins with option where I can choose what I want to build - release or debug.

I can't find any useful article how i can do this in my android application.

Any help is highly appreciated!!

Upvotes: 1

Views: 934

Answers (1)

Ivan B
Ivan B

Reputation: 414

Solution is very simple. I'm build my app using grade script

  1. Add build parameter "Choice parameter" with any name(In my case name is "BUILD_TYPE")
  2. Add choices, in my case they are "Debug" and "Release"
  3. In section "Invoke gradle script", in "tasks" write this - "clean assemble$BUILD_TYPE"
  4. Save changes

Done! Now you will choose debug or release, and Jenkins will provide you with different build types of your app

Upvotes: 2

Related Questions