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

Can't check in files in SourceTree

Dave T July 13, 2014

I'm a first time user of SourceTree and am trying to check in an existing project into BitBucket. Sorry, this is probably simple but I can't figure it out. I am working from a Windows computer and have a set of source code in a directory on the computer. How do I check it in? I tried drag and drop into the bookmarks section in the left pane of the SourceTree client, but no-go.

Or if there is any documenation anywhere, can you point me to it?

1 answer

0 votes
Seth
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.
July 13, 2014

If your existing code is already a Git or Mercurial repo, you can add it to SourceTree using the "Add Working Copy" tab in the Clone/New dialog. Otherwise, add it to SourceTree in the "Create New Repository tab. You may have to commit the code to the new repo.

In Bitbucket, create a new repository. Add this new repo to your SourceTree repository as a remote. Push your branch to the Bitbucket remote.

Dave T July 14, 2014

Thanks, but can you give me more detailed instructions (or point me to some documentation -is there any)? I created the repository, and it seemed to let me add my code, but when I go to view the tree in bitbucket, there is nothing there.

Seth
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.
July 14, 2014

Have you used Git before? Your confusion sounds like it stems from a misunderstanding of the differences between Git/Hg versus CVS/SVN.

Dave T July 14, 2014

You're right - I've used GIT but am rusty. I am more experienced with CVS and SourceSafe. That's why I could use some doc. What I want to do must be pretty straightforward - just initialize a new repository with an existing project, but I can't get it to work!

Dave T July 15, 2014

Sooo... a little help please?

Seth
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.
July 15, 2014

Yeah, I thought I responded, but it disappeared.

SourceTree is not just a desktop interface for Bitbucket. According to the design of Git (and Mercurial), you are actually working with two distinct repositories. One of those repositories resides on your local machine, optionally managed by SourceTree. The other resides on Atlassian servers, managed by Bitbucket.

You can (and should) link these repositories to each other by configuring your local repository to view the Bitbucket one as a "remote".

Once Bitbucket is a remote, it is important to know the differences between your operations. Some, like "Commit" and "Checkout", usually operate only on your local repository. Others, like "Push" and "Pull", are used to syncronize the local and remote repos.

To add a remote, go to the Repository menu and choose "Repository Settings..."

Dave T July 15, 2014
Aha! I am away from the computer so can't test this now, but I'm sure that's it. Thanks! But my other question is - is there any documentation for SourceTree?
Seth
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.
July 15, 2014

The only official documentation I've heard of is in the Help menu on the Mac version. It will be added to Windows "soon" (according to Atlassian staff months ago).

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events