Can I configure SourceTree to prompt for user credentials on start or activity?

I have client computers that I want to require the entry of user name and password before they can interact with the remote.  I want it to be one of our developers who does any pushing/pulling, not a lab tech.  Ideally, they also could not "add a new repo" and see the list of repos (my other clients) on Bitbucket.  If there is a better approach I am open to it.

1 answer

0 vote

Hi

I'm assuming this is Sourcetree for Windows and that Sourcetree does not provide the kind of fine grained control you are looking for.

If you delete any Accounts in Tools/Options/Authentication then Sourcetree will not be able to list remote repos on Bitbucket.

If you are using private repos anyone trying to push will be prompted for valid credentials, but by default Git will cache those credentials for use the next time.

You can turn off this caching, see https://git-scm.com/docs/gitcredentials

If credential.helper is configured to the empty string, this resets the helper list to empty (so you may override a helper set by a lower-priority config file by configuring the empty-string helper, followed by whatever set of helpers you would like).

This potentially would prevent caching and mean the use is prompted everytime ... but Sourcetree expects the standard git credential manager to be in place and working to manage the credentials. I've never tried this but I suspect it will prevent pushing/pulling from Sourcetree but you might need to switch to the command line when you do actually want to enter credentials and push to the remote.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Brian Ganninger
Published Jan 23, 2018 in Sourcetree

Tip from the team: workflow and keyboard shortcuts

Supported Platforms macOS Sourcetree has a lot to offer and, like many developer tools, finding and using it all can be a challenge, especially for a new user. Everyone might not love ...

647 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