Vince Vince - 1 month ago 11
Git Question

Bamboo + Stash: Please tell me who you are

I'm trying to run a maven-job with Bamboo and release a project with the maven release-plugin. However, when Bamboo tries to commit something, the following error appears:

19-Nov-2013 13:20:37 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.0:prepare (default-cli) on project Projectname: Unable to commit files
19-Nov-2013 13:20:37 [ERROR] Provider message:
19-Nov-2013 13:20:37 [ERROR] The git-commit command failed.
19-Nov-2013 13:20:37 [ERROR] Command output:
19-Nov-2013 13:20:37 [ERROR]
19-Nov-2013 13:20:37 [ERROR] *** Please tell me who you are.
19-Nov-2013 13:20:37 [ERROR]
19-Nov-2013 13:20:37 [ERROR] Run
19-Nov-2013 13:20:37 [ERROR]
19-Nov-2013 13:20:37 [ERROR] git config --global user.email "you@example.com"
19-Nov-2013 13:20:37 [ERROR] git config --global user.name "Your Name"
19-Nov-2013 13:20:37 [ERROR]
19-Nov-2013 13:20:37 [ERROR] to set your account's default identity.
19-Nov-2013 13:20:37 [ERROR] Omit --global to set the identity only in this repository.


I searched the Bamboo settings and Google to find a way to set those identity-information, but I didn't find anything useful. Does anyone know, how to set those?

Answer

It's right there in the error message: run two "git config" commands. You have to run those commands as the user that executes the build, so you presumably need to do something like a "sudo su bamboo" before you begin.

The two values will end up in the .gitconfig file in the home directory of your Bamboo user:

[user]
name = Bamboo Server
email = bamboo@yourcompany.com

You can also edit this file in a text editor.