This error means git can't find the username for the repo when run with terminal prompts disabled. You should be able to reproduce this by trying to clone the repo yourself like so:
$ GIT_TERMINAL_PROMPT=0 git clone https://bitbucket.org/org_name/repo_name
git is requiring you to enter the username manually because it does not have a credential stored.
Since you're using fastlane, I'm going to assume the most likely cause: you're on macOS but you haven't configured the git-credential-osxkeychain
tool which provides credentials from the keychain to the git
command line tool.
Run
$ git credential-osxkeychain
to verify the tool is installed.
If this fails, either install Xcode command line tools, or run brew install git
to install it.
Run
$ git config --global credential.helper osxkeychain
to configure the tool.
- Clone your repo (
git clone …
) as normal and login
Now your BitBucket credentials should be stored in your keychain and both GIT_TERMINAL_PROMPT=0 git clone
and fastlane match should succeed.
If you're not on macOS, you'll need to install and configure a similar credential.helper
for your operating system.