Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

multiple users accessing same repositories in source tree

Claire Bresee January 4, 2016

How can we have more than one user access the same repository in sourcetree? I saw this question answered already but the instructions are outdated. I've managed to create multi user access to these file commits in Bitbucket so far, but we all need to be able to commit and push from sourcetree.

4 answers

1 vote
mkarda May 24, 2016

I am actually interested in this as well.  

In our case i have a local repository on one of our servers.  I created the repository and access it through source tree.  Someone else needs to access it as well through source tree.  I put their login in the Bitbucket team so they can access it there, but when i added the working copy to his source tree it prompted for my login. Any thoughts?  Or should i be looking for this in a Git forum instead of an Atlassian one? 

0 votes
thinsoldier
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 26, 2016

In Bitbucket project settings under Access Management make sure their username is there and that you have them set to either write or admin.

0 votes
Tim Crall
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2016

Git is a distributed version control system.  Each user should be working on their own clone of the repository.  

mkarda May 25, 2016

That makes sense, but say i have a folder in the website that is not really managed with the other code.  It contains files that are not in the solution, so wouldnt get deployed when i build the site.  I used a repo where the local is mapped right to the server drive.  Im not the only one who needs to be able to manage this repository.  And this folder does need to be in source control.  I have to avoid the he-said she-said problem when images or js files change.  

Tim Crall
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 25, 2016

I'm not totally clear on your use case, but it sounds like maybe that directory should be it's own repo?

mkarda May 25, 2016

The directory is its own repo, and 2 people need to be able to access it.  We have the "remote" repo in bitbucket, no issue there, but the "local" repo is on our web server.  Thats where multiple people would change it, or at least do a pull.  

thinsoldier
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 26, 2016

If the repo is on your web server you can't really call it "local".

Each person should have a "local" clone of the repo on their personal workstation. They should do their work in their own local branches and make sure their changes are good somehow (test server separate from the live web server) and then either merge and push their changes (or make a pull request to whoever is in charge of the project) to Bitbucket and then ssh into the web server and git pull to update the website. 

There is no "he-said she-said problem" with version control. Each user should have their own identity configured with their name and e-mail address and each commit identifies the person who made it and each line of each file can tell you which commit last changed it.

mkarda May 26, 2016

That is how it is set up, all save for the part where I want to avoid having this guy ssh onto the web server to do the pull.  Im already getting enough flak from him because he needs to even check stuff in.  

And the repo on the server is the local one in git, thats why i said it was local.  I understand that the local should be directly on your machine.  The way i set it up was to have the "local" repo come down to a network drive.  

Is there another way i could have him initiate the pull remotely?  

I do apologize for getting a bit out of the scope of this post, but i appreciate the input.

0 votes
Tim Crall
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 4, 2016

I'm a bit confused. Would these multiple people be working on their own individual workstations with a copy of SourceTree installed? If so, there should be no problem. Git is a distributed version control system. Your centralized repo is on Bitbucket, then each developer clones a copy of the repo to their own workstation, uses SourceTree or the git command line to add commits, and then pushes back to the centralized repo.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events