BitBucket Pipelines Gradle build for Android - failed

My settings:

image: uber/android-build-environment:latest

    - step:
          - mkdir "${ANDROID_HOME}/licenses" || true
          - echo "8933bad161af4178b1185d1a37fbf41ea5269c55" > "${ANDROID_HOME}/licenses/android-sdk-license"
          - bash ./gradlew build crashlyticsUploadDistributionRelease

FAILURE: Build failed with an exception.
* Where:
Build file '/opt/atlassian/pipelines/agent/build/build.gradle' line: 52
* What went wrong:
A problem occurred evaluating root project 'build'.
> For input string: ""


What could be the cause of the error. Looks like that is something wrong on server.

1 answer

0 votes

Hey @Miłosz Skalski

Everything looks correct, the only thing I'm not sure about is how you invoke the gradle wrapper; if you turn that last line into

bash -c "./gradlew build crashlyticsUploadDistributionRelease"

 does that improve it? I'm thinking that the arguments "build" and "crashlyticsUploadDistributionRelease" are going to bash, not to gradlew



Hey @Sebastian Cole

The problem is not related with:  crashlyticsUploadDistributionRelease.

Problem occurs related with don't installed git on image. Always when I commit something I counts commits.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 06, 2018 in Bitbucket

Upgrade Best Practices

Hello! My name is Mark Askew and I am a Premier Support Engineer for products Bitbucket Server/Data Center, Fisheye & Crucible. Today, I want to bring the discussion that Jennifer, Matt, and ...

426 views 6 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you