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 Join to answer
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

654 views 0 4
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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot