youngmon/atlassian-qna huggingface dataset:
Am I getting ip-banned because of SourceTree connections to my remote machine?
Asked by mrbohnke:

I use SourceTree for Mac. This started happening today...

Every time I open SourceTree and it connects using ssh and checks for changes on all the repositories (all of them in the same place), I get ip-banned...

If I do a top on the remote machine before opening SourceTree, then open it, I can see how it makes a login for every repository... and then suddenly everything freezes and my remote machine does not answer at all any more until I reboot my router for the IP to be changed...

![](http://f.cl.ly/items/3k372R1G063M2d3a0d3C/Captura%20de%20pantalla%202013-06-21%20a%20la(s)%2013.00.40.png)

My hosting provider is Dreamhost, if you guys think this is not SourceTree-related, I'll talk to them.

Thanks!


Answers:
author: mrbohnke
body: SSH, both.

It was finally hosting related. I'll paste their answer for future reference:
> Hello,
>
> I am very sorry you have had this trouble. Our security system administrator has looked into this matter, and found the the server's jail.local file was missing the correct override for the number of failed login attempts, causing the login to be blocked prematurely by our fail2ban routine.
>
> He has corrected this, and you should no longer have this problem. I am sorry for the inconvenience this as caused, but happy to report the problem has been resolved.

Thank you anyway,

Cheers!


author: mrbohnke
body: Thanks Kieran.

Sadly, that didn't help. I turned "check default remotes for updates..." off but, as soon as SourceTree connected the first time when I tried to do a git-pull, connection freezed.

Note: This doesn't happen when I use git on terminal!

comments: author: KieranA
body: Are you using SSH or HTTPS in SourceTree and on the command line?


author: KieranA
body: Hi Se?or,

SourceTree does do checks in the background to see if there's any changes to pull. If you want to test if this is causing the problem you could turn this feature off in the preferences (General tab) as shown here:

![](http://i.imgur.com/kiIhpLu.png)

Just turn off the "Check default remotes for updates every \<X minutes\>" checkbox and it won't do any background checks.

If your hosting provider is having a problem with this then it's worth speaking to them about it. In the meantime you can turn this feature off and manually hit fetch or pull on your repository. It doesn't stop you from pulling changes, it just stops background checks from happening to see if there is anything to pull.

Hope that helps
Renaming a file doesn't work
Asked by Chris Rusby:

I'm trying to rename a file from tradinghistory/settlementReports/2013/20130327 Report_Statement (1).csv to tradinghistory/settlementReports/2013/20130327 Report_Statement.csv. When I do this via the move command, it moves it to tradinghistory/history/settlementReports/2013/20130327 Report_Statement.csv - i.e. it adds an extraneous "history" directory in the target.If I rename source files from within IntelliJ, this works, but the same issue happens within SourceTree.Thanks


Answers:
author: Chris Rusby
body: Created <https://jira.atlassian.com/browse/SRCTREE-1669> but I don't think I have the ability to assign to you. Thanks!


author: KieranA
body: Hi Chris,

I've just tried this using your exact same file structure and filenames and have been unable to reproduce the problem you're describing. Could you re-test this? Are you sure there isn't another folder tradinghistory/history which has the same file structure and you're actually trying to rename that a file in that directory instead?

Thanks in advance

comments: author: Chris Rusby
body: Hi Kieran,Thanks for your reply.It's 100% repeatable, which is good and bad I guess! I have a set of 4 jpgs which I can send you to show the problem, maybe you could let me know where I can upload them?Also, I suspect this isn't the right forum to be raising bug reports, so please let me know if there's a better place for me to be reporting this.Thanks,Chris


author: KieranA
body: Hi Chris,

You're right, JAC is where we have bug reports over at [jira.atlassian.com](http://jira.atlassian.com). The project name is SRCTREE and you can assign it to me. Just detail as much as you can and we can go from there.

Thanks!


author: MikeL
body: Why don't you use your file manager to rename/move the file? You then will see an untracked and a missing file, but after committing both, the history will be linked.

comments: author: Chris Rusby
body: Yes I can do this, but I don't see how it's going to keep track of file history. For instance if I have FileA.java and FileB.java, if I delete these and add FileC.java and FileD.java I think it would be pretty amazing if SourceTree could figure out whether FileA.java was renamed to FileC.java or FileD.java....


author: MikeL
body: Not SourceTree is amazing in detected renamed file history, but Git is - and hence every Git client. Check out [http://stackoverflow.com/questions/1094269/](http://stackoverflow.com/questions/1094269/whats-the-purpose-of-git-mv)
Sourcetree classroom licensing
Asked by cunneen:

Hi,

Atlassian already provide great support to our students with BitBucket. I encourage all of my students to use it. Thank you for that excellent service.

My question is about SourceTree licensing. Can we deploy SourceTree in our classrooms? If so, should we use multiple copies of a single license, or is there a special license available for this?

Thanks!


Answers:
author: stevestreeting
body: Hi Mike,

You can definitely deploy SourceTree in your classrooms - you're quite welcome to use a single licence file created with a shared Atlassian account for all the machines, either by logging in on the registration dialog on those machines to download the license, or by manually copying the sourcetree.license file across machines, which lives here:

Mac: \~/Library/Application Support/SourceTree/sourcetree.license

Windows: %UserProfile%\\AppData\\Local\\Atlassian\\SourceTree\\sourcetree.license

You can either copy those files across machines or copy it from one master machine and use the 'Import License' option in the registration dialog. The same license works across both platforms.

HTH

Steve

comments: author: cunneen
body: Thanks for the prompt and helpful answer Steve, that helps a lot.
Sourcetree made home dir a git repo. How do I remove?
Asked by ED:

Total newbie. Sourcetree made home dir a git repo. How do I remove git repository pointing to home folder without deleting my files? Thx


Answers:
author: KieranA
body: Hi Ed,

In your home directory there'll be a ".git" folder which is hidden if you use finder/explorer. Go to the command line / terminal and browse to that directory. If you issue the command "ls -a" (on Mac) or "dir /a" (on Windows) and it should show a ".git" folder. You can delete this folder by either issuing the command "rm -rf .git" (on Mac which recursively removes the folder and sub-folders) or "rmdir .git /s /q" (on Windows which recursively removes the folder and sub-folders without prompts).

Make sure you specify the .git folder and your current directory is where the .git folder exists as this is a destructive operation.

Hope that helps
Unshelving across branches performs unwanted merge
Asked by incidentist:

To reproduce:

1. Shelve an uncommitted change on a branch.
2. Update to another branch.
3. Unshelve the change you shelved.

What should happen: The shelved changes should be applied to the new branch, and that's all.

What happens: The shelved changes are applied, but any differences between the first and second branch are also applied, effectively doing an unwanted merge.

None of the hgattic documentation discusses what's expected behavior when unshelving to a different branch, but my co-workers and I often need to move uncommitted changes to another branch, and the Shelve command is very unpredictable. We work around it by:

1. Creating a patch with the uncommitted changes
2. Revert all.
3. Update to the other branch.
4. Apply the patch.

However, SourceTree's interface for using shelves is much more intuitive and convenient than using patches, and we'd much rather use shelves if they did what we want.


Answers:
author: KieranA
body: Hi Dan,

If this is in Mercurial this is due to a bug in the shelve extension we use from Mercurial. We've actually got a planned bugfix on this front but no-one had reported it until now. You're right that this is completely the wrong behaviour, it should only unshelve the changes that are in the shelved changeset.

We're planning on moving away from hgattic for a number of reasons, one being for partial shelving and the other to fix this bug.

Thanks for listing the workaround, I'll make sure I take note if anyone asks in the meantime. We'll look at getting this in sooner than we planned as it's extremely difficult to fix if you do apply the shelve.

The related issues on JIRA are <https://jira.atlassian.com/browse/SRCTREE-1460> and <https://jira.atlassian.com/browse/SRCTREE-1375> currently scheduled for 1.7 but I'll squeeze these into a 1.6.x release instead.

Thanks for the information

comments: author: incidentist
body: Thanks, Kieran! This will have a huge benefit for our team of 20 engineers.


author: Roger Versluis
body: Hi guys, is there already a time line for this fix? The Patch workaround doesn't work either because patching is broken.
Cannot see color branches in log mode (sourcetree)
Asked by Newbie:

Newbie question. I have been using xCode5 and decided to move away from xcode git and to SourceTree. I am keeping my code local on my machine but would like to get into the git flow habit. I opened Sourcetree and imported my project. All looks good. I did a final commit and initialized GitFlow. But as I move from Master branch to Development Branch to creating Feature Branches, I see the branch names in the log, but I do not see the parallel gitflow lines. Is that because my project is local and I am not doing any Pull/Push? or am I missing a setting? Thanks


Answers:
author: KieranA
body: Hi Khaled,

One thing this could be is that because perhaps you're the only developer and you're moving entirely in a sequential manner meaning Git may do a fast-forward merge (this is by default). An easy way to understand this is from the Git config docs:
> By default, Git does not create an extra merge commit when merging a commit that is a descendant of the current commit

This may be true in your case. Additionally, in SourceTree your log view may have certain options set causing your history to look different than expected. Just above the graph there are filters (drop down lists). Perhaps make sure the first one is set to "All Branches" and see what that yields?

Have a play around with the log filters and consider that all of your branching and merging may have been fast-forward merges.

Hope that helps


Tags: git-flow
How can i find a commit by date
Asked by Stephan Krau?:

Hello !

Sorry for my bad english.

I'm a beginner in Git. In my project there are some commits.

How can i find a commit by date ?

Your sincerly

Stephan


Answers:
author: KieranA
body: Hi Stephan,

Assuming you're using the Mac version there's a "Search" view allowing you to filter by date as shown in this screenshot:

![](http://i.imgur.com/BCUhuF2.png)

Hope that helps


author: Stephan Krau?
body: Hello !

Thanks for the answer. But i work with windows 7 and sourcetree version 0.9.2.3

Any idea ?

Your sincerly

Stephan

comments: author: stevestreeting
body: Firstly, please note that you're a little behind in versions - please grab the latest version from [sourcetreeapp.com](http://sourcetreeapp.com) (the [installer has changed](http://blog.sourcetreeapp.com/2013/05/13/new-installer-updater-for-sourcetree-for-windows/)).

There isn't a date search in the Windows version yet. My research indicated hardly anyone used it so that view was simplified - you can always scroll back in time in the log to examine a date range. Do you need a combination of other search terms AND date range?
Git Remote Helper
Asked by Greg Lusk:

I am using SourceTree on Mac. I have a remote helper set up that allows my native Git client to connect to a Mercurial repository. When I attempt to clone my Hg repo with a URL like 'hg::\<url\>', SourceTree reports that Git cannot find a remote helper. I have SourceTree set up to use my native Git client, and my Git client can clone from the command line.

Can you suggest how I can make this work with SourceTree?

Thanks,


Answers:
author: stevestreeting
body: I'm guessing you've made some changes to your PATH or other environment settings in your terminal in order to make the remote helper work there. On the Mac, changes to the terminal's environment are not visible to full OS X apps, because they are launched by a service called 'launchd' and not via sh/bash where you would have made your environment changes.

You can tackle this 2 ways:

1. Make your helper not reliant on additions to the environment, so don't rely on additions to the PATH etc, or
2. Alter the environment that affects OS X apps too. This means editing /etc/paths or adding files to /etc/paths.d to alter PATH, or editing /etc/launchd.conf to set other environment vars (also \~/launchd.conf). See <http://www.dowdandassociates.com/content/howto-set-an-environment-variable-in-mac-os-x-slash-etc-slash-launchd-dot-conf/> for the format.

comments: author: Fernando L. Garcia Bermudez
body: @Steve, I've made sure that git-remote-hg is in the path (symlinked it to /usr/local/bin, which is part of /etc/paths by default) and am able to use it from the terminal by issuing:

```
# git fetch origin
```

where

```
# git remote -vorigin	hg::/path/to/origin (fetch)origin	hg::/path/to/origin (push)
```

When I launch SourceTree and try to fetch from that remote in the GUI, I get:

```
git -c diff.mnemonicprefix=false -c core.quotepath=false -c credential.helper=sourcetree fetch origin fatal: Unable to find remote helper for 'hg'Completed with errors, see above
```

Any idea why this might not be working? I didn't add the path to /etc/paths.d as it'd be redundant there and I haven't yet tried modifying launchd.conf.

I'm running system git version 1.8.4.3 installed via homebrew under /usr/local.


author: KieranA
body: @Fernando,

It's important to note that SourceTree runs in its own environment entirely, and thus has its own PATH env var. If you've set up a remote helper for your repository and that helper is located on your PATH env var ('echo $PATH' on the terminal) then it won't be available from SourceTree.

This is just the way Mac apps work unfortunately.

Cheers


author: Fernando L. Garcia Bermudez
body: @Kieran,

That's what @Steve had noted in his answer, but he also gave a few suggestions on how to ensure that the helper appears in SourceTree's PATH. This is somehow not working for me, so maybe I'm misunderstanding his answer.

If I can't control what's in SourceTree's PATH, maybe I can just symlink git-remote-hg to a folder already accesible to it. What's its default PATH?

Thanks!


Tags: helper

remote
How Stash integrates with Visual Studio and Jira?
Asked by Alex Catano:

I have two questions:

Can Stash get integrated with Visual Studio through your IDE connector and how it affects to Jira?

Can I use another repository manager like SourceTree/ SmartGit/ GitHG integrated with Visual Studio and Jira?


Answers:
author: Jens Schumacher [Atlassian]
body: We don't have plans to integrate Stash with Visual Studio via the IDE Connector in the foreseable future. We recommend SourceTree to manage your Git repositories on Windows.

<http://www.sourcetreeapp.com/>

Note that SourceTree and SmartGit are not repository management tools. They are local clients that talk to the remote repository.


Tags: bitbucket

bitbucket-server

ide-connector

integration

visual-studio
How to make Sourcetree use common GIT.exe?
Asked by lavanyadeepak:

I have a TortoiseGIT and mSysGit.exe which I have configured to handle my GIT server (SSL) with a self-signed certificate. But now with SourceTree that common environmental variable is not respected and it wants its own settings to disable SSL verification because I believe SourceTree has its own private GIT.exe

Is there a way, I can have SourceTree to use the common GIT.exe as Tortoise GIT?


Answers:
author: stevestreeting
body: Tools \> Options \> Git \> Use System Git

Please note however that this is designed to work with the standard Git from <http://git-scm.com> and not TortoiseGit's version. But any reasonably recent version laid out like the standard version should work fine.


author: stevestreeting
body: Tools \> Options \> Git \> Use System Git

Please note however that this is designed to work with the standard Git from <http://git-scm.com> and not TortoiseGit's version. But any reasonably recent version laid out like the standard version should work fine.
is Source Tree free for business use?
Asked by adc_admin:

We're planning to use Source Tree for business use. Is its license free for it? Or, are there any commercial lisence ? If so, please let me know URL which is written about it.


Answers:
author: KieranA
body: Hey Kaori,

As long as you're not selling SourceTree then you're more than welcome to use it in your company. Many companies use SourceTree to manage their repositories as it's completely free - we don't limit SourceTree's usage to non-profit organisations whatsoever, so feel free.

Hope that helps

comments: author: adc_admin
body: Hi Hieran,

Thanks for your quick answer. Wow, Great!! Thank you so much!!!!!


author: Vishal
body: Kieran,

Is this still true in 2016? I am learning sourceTree and don't want to switch to another product or git command if I cannot use it in my company.

Thanks

Vishal


author: Andreas Ramig
body: is it still up to date?
No New Files or Directories Are Showing
Asked by ardan_bkennedy:

I have been working great and now no new files or directories showup. I have tried everything including removing and re-installing SourceTree.


Answers:
author: KieranA
body: Hi William,

There's a number of reasons this could be happening. The main two reasons are that you could've added an ignore pattern that would exclude all files from your root directory showing up for example. This would've been done by going into your repository settings (there's a settings button in the top right of your repository window) and on the advanced tab the top section shows your repository-specific ignore file which you can click 'edit' on to show your ignore patterns.

Alternatively you may have simply changed your view options so it will only show certain files. Make sure it's set to "Show Pending" as the screenshot below shows:

![](http://i.imgur.com/jmaQUeZ.png)

If you could check the above two suggestions first and if neither work we can investigate further.

Hope that helps
Change commit code to other branch (Sourcetree for Windows)
Asked by Xavier Pimienta:

Hi!

I am newbie with this tool and Git.

I put a 'new' branch code in 'master' branch, how can I change it to put in the right place?

Thanks a lot!!!

Xavier


Answers:
author: stevestreeting
body: That depends:

1. If you haven't committed the change yet, you can just create a new branch (or check out another branch) right now and then commit. If there are conflicting changes in the other branch you can Stash your changes before switching, then Apply the stash again afterwards.
2. If you have committed the change, but you haven't pushed it to anyone else, you can right-click on the commit \*before\* that commit and use the 'Reset branch to this commit' option to move the master branch backwards, undoing that commit. The default 'Mixed' mode should be used in the reset dialog so that your changes still exist in your local folder, they just become uncommitted again. Then, go to 1.
3. If you've committed the change \*and\* you've pushed it, then you can't undo it because other people may have already seen it. You can copy the commit to the other branch by checking out the other branch then right-clicking that commit and selecting 'Cherry Pick'. This will copy that commit over to your other branch but won't undo it on master.

HTH!

comments: author: jonathan
body: Thank you for a very useful reply!

Regarding #3 it's really not possible to delete commits already pushed to origin? Even if I'm the only contributor?

Thanks!


author: Jens G?ssing
body: Hey, very good explanation of the options. Thanks.

I need top go for option "2." but don't know whether to do this on master or on the branch the commit was meant to go to?


author: Jens G?ssing
body: ... think I just figured it with common sense. It's to be executed on the master and of course the right click needs to be on the previos entry (BEFORE the "wrong commit") ...


author: Johannes Herrmann
body: Thank you :)

Helped me a lot!


author: Tauqir Pervez
body: Thanks, exactly what I was looking for! :)


author: Elias Simon
body: For the (2) scenario, is there a way to avoid re-commits? In Mercurial, you can change the working directory, change the branch, and then graft the commits over, rather than having to make new ones.


Tags: branch
SourceTree & remote git repo
Asked by radu margarint:

Is there a way to run SourceTree managing a remote git repo? By remote, I mean a git repo which isn't mapped on the machine SourceTree is running, but on a remote machine. My scenario is that the code base I'm working on is a server code base, and a very very large code base. We don't pull the source to our client machines, or build or run. It's all on a dedicated dev servers running Linux, and we just ssh into them, or map the file system and use some client side editor to edit the files. I would \*really\* like to use SourceTree for diff management. However I can't find a way in our setup. If I point ST to the locally mapped remote tree, it hangs at start up forever (probably because it's scanning the entire tree or something). It would really be nice if we could setup ST to basically run all it's required git operations via ssh on a remote repo.


Answers:
author: stevestreeting
body: No, this isn't on the cards I'm afraid - DVCS tools major benefit is that they run on local data stores and so are very fast; for this sort of usage you should either clone to your local machine or use some kind of server-side web interface if you want to do it remotely.
Resize commit and diff windows (Log view) in SourceTree for W7
Asked by Julieta Jakubowicz:

Hello, my coworkers running SourceTree on Macs seem to be able to expand the window to view the line by line diff but a simple click and drag, but I can't. Is it a bug in the Windows version?


Answers:
author: LarsM
body: In the Windows Version its almost the same. I just tried in the current SourceTree Windows Version and it works fine for me.
restore
Asked by ???:

com.atlassian.confluence.importexport.importexportException????????????? Confluence ?????????????JDBCSQL ???????


Answers:
author: Fabio Racobaldo _Herzum_
body: Hi [@???](/t5/user/viewprofilepage/user-id/5238422) and welcome,

there is some issue in the xml file. A similar error appears for duplicated key (<https://confluence.atlassian.com/confkb/confluence-site-xml-import-fails-with-duplicate-key-error-438993638.html>). In your case it seems that there is some item with NULL value.

Try to create again the xml file.

Fabio


Tags: confluence-server

server