It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Pushing back to your repository

55 comments

+1 for branch permissions when using HTTP, somehow.

Like Matthew Petrie likes this

+1 for branch permissions for CI

is it necessary to have the pipeline fail on a git commit that doesn't have anything to commit?

i guess the simplest workaround everyone is doing is providing an echo output to a file prior?

will this pipeline failure on nothing to commit always behave like this or is there any change in the works?

 

thx for any info.

 

-jw

If you don't want a pipeline failure on a git command, use the "OR" operand || to allow the command to return 0:

- git commit -a || echo "Nothing to commit"
- git push || echo "Nothing to push"
Like Johnnie Walker likes this
Alex Tran Atlassian Team Jul 22, 2019

 

Pushing back using the http origin to repositories where branch permissions are enabled is not yet supported. 

+1 to have this supported as we are using branch permission.

 

Our current workaround is to switch to SSH before pushing

git remote set-url origin ${BITBUCKET_GIT_SSH_ORIGIN}

Comment

Log in or Sign up to comment
Community showcase
Published in Bitbucket Pipelines

What We Learned When We Researched Open Source Vulnerabilities in 7 Popular Coding Languages

...hey are a part of us, shaping how we interact with the world around us. The same holds true for programming languages when we think about how different kinds of vulnerabilities raise their heads in t...

398 views 0 1
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you