git

How do I enable msysgit colored output when using console2

I'm having a hard time enabling git colored output on windows when using console2. To trick git I've already SET TERM = 'cygwin'. This enabled the colors from a standard cmd.exe prompt but not in console2. I've verified that console2 can see the env var as well. Anyone know how to get this working? ...

Share pre-initialized GIT repository

We were sharing a GIT repository via file-sharing system (smb://) and got it badly corrupted (a power cut meanwhile the post-send :P). Being new to GIT, trying to fix it I made it even worse and I lost all the refs (left with the object folder). Since the incident I haven't had the time to look at the problem and have just been keeping ...

explain command for git delete remote branch

Hello, The command to remove a remote branch in git is the following git push origin :/heads/[feature-name] [feature-name] being the name of the branch This does the job perfectly, true that. However by typing it, I can make no association that what I type is actually deleting a branch. Can you please describe why this act...

How to configure Hudson and git plugin with an SSH key

I've got Hudson (continuous integration system) with the git plugin running on a Tomcat Windows Service. msysgit is installed and the msysgit bin dir is in the path. PuTTY/Pageant/plink are installed and msysgit is configured to use them. When I run a job that attempts to clone the git repository I get the following error: $ git clone...

Can I have a workspace that is both a git workspace and a svn workspace?

I have checked out now a local working copy of a codebase that lives in an svn repo. It's a big Java project that I use Eclipse to develop in. Eclipse of course builds everything on the fly, in it's own way with all the binaries ending up in [project root]/bin. That's perfectly fine with me, for development, but when the build runs on...

What is Repo and Why does Google use it?

When I wanted to get Android source code, I knew that I have to use "repo". So what is repo? Why do they use repo and not just use GIT?, and is there a GUI for repo that enables me to pause/resume syncing, because every time I get disconnected occasionally it seems that repo starts syncing from the beginning! ...

Gerrit with Github

I am using github and I am willing to start using Gerrit with it. Since Gerrit uses JGit, I am scared of the following text from this link: EGit/JGit is a reimplementation of git in java, due to this GitHub does not officially support it. Issues have happened and repositories have been corrupted by them. While it is usually ...

master branch and 'origin/master' have diverged, how branches to 'undiverge'?

Hi Guys, I'm kind of a git Noob and somehow I got my master and my origin/master branch to diverge. I actually don't want them to be diverged. How can I view these differences and 'merge' them? ...

Git directed acyclic graph - children know their parents but not the other way around

Git is implemented as a directed acyclic graph. Children know their parents but not the other way round. This makes sense because i can reach every commit only through a branch or a tag ( generally speaking through a reference). That's how i traverse the tree. What other reasons had the developers of Git to make "the children know their ...

Using a single visual studio 2005 solution with multiple source control applications

In my recent SO question I was helped tremendously in using git as a front-end to ClearCase. However actually trying the suggested answer(s) led to further complications. Visual Studio keeps a reference to the used source control provider in both the .sln as well as the .csproj files. I tried resolving this issue by keeping a modified co...

Anyone use both Tortoise Git and Subversion on the same machine?

Anyone install both? Using each for separate projects obviously. Shouldn't be a problem, I'm guessing, but hoping to fish out any gotchas. Furthermore, anyone use Tortoise Git, Subversion and Mercurial on the same machine? Edit: Forgot to mention, this is for Windows 7. ...

Git - git add in a gitignore directory

If my .gitignore file has tmp\ in it and I do a git add file.test from tmp, Git adds file.test to the repository. If file.test never changes, than this is as good as a one time add to the repository, right? Say for static files that I want to be in version control. You want the file in an initial clone and that's it. I assume file.t...

Is there a way to setup remote-specific .gitignores?

Is there a simple way to setup different .gitignore files for different remotes? I have a repository I push up to both Heroku and Github. I need database.yml for Heroku, but don't want some of the information to be pushed up to Github. So I need a different .gitignore file for each of the remotes. I tried having two separate branch...

git encrypt/decrypt remote repository files while push/pull

Is it possible to automatically encrypt files via 'git push' before transferring to a remote repository? And automatically decode them while 'git pull'. I.e, if I have some remote server with shared access with git repository there, and I don't want to our project was stolen without a permission... Maybe there is some special git-hooks ...

Adding folders to a git repository while ignoring some subfolders

Im trying to add a directory "foo" to my repo, but there are some sub dirs lets call them "bar1", "bar2", "bar3" and "bar4" Now I want to add foo to my repo, while ignoring foo/bar2 and foo/bar3 is this possible? do i need to add them first and then remove the folders I dont want? ...

Is there a tool that automatically saves incremental changes to files while coding?

One of my favorite features of Google docs is the fact that it's constantly automatically saving versions of my document as I work. This means that even if I forget to save at a certain point before making a critical change there's a good chance that a save point has been created automatically. At the very least, I can return the documen...

Restore file's modification time in git

I understand the default git behaviour of updating the modification time every time it changes a file, but there are times when I want to restore a file's original modification time. Is there a way I can tell git to do this? (As an example, when working on a large project, I made some changes to configure.ac, found out that autotools d...

Reference Git branch start commit.

Hi I am trying to find how to reference branch start commit from script. I mean the commit sha at which branch was forked. Moreover I expect it work for history made from svn repo. http://stackoverflow.com/questions/1006775/git-how-to-reference-the-initial-commit/1007545#1007545 just gives first commit of repo creation and not feature...

Cannot combine commits using TortoiseGit

I have two branches with several commits each. On one branch, I can go to the log, select two commits, and TortoiseGit shows "combine to one commit" in the context menu. On the other branch this option does not show in the context menu. Both sequence of commits is very similar; add file then modify it, so there is no difference really be...

Shared Git repo syncing to svn causing git svn rebase to pollute repo with a log of no-op merge problems

This wasn't so bad at the beginning, but now I have hundreds of no-op merge problems (solved by git rebase --skip). I have setup a shared git repo for my group because it is easier to deal with. But the company uses SVN so I have to keep SVN in sync with GIT. Worked like a dream at first, but after weeks of doing this GIT is giving me...