git

Using Qt Creator with Git version control

I’ve recently installed git and initialized a git repo in my project folder. I can commit and checkout without any issues through the command line, but for some reason the gui in qt creator claims my connection has timed out. Im running windows…. Any ideas? Error message(s): 21:15 Executing: git status –u Unable to obtain the status: E...

Git create branch from current checked out master?

There is a git controlled folder on a server where the main branch is checked out and a whole pile of files have been modified and not committed. Is there a way for me to commit the changes to a separate branch so I can go back to a clean version? ie I want to effecitvely undo all this persons changes but store them in another chance ...

Keeping track of source code variants

Hi! I am soon starting to maintain a line of products containing variants of the same embedded software. Since I've been playing with git for one year and appreciate it very much, I'm likely to use it for source control. There are several options I can see for maintaining the variants of the firmware, but none pleases me too much. What...

How can I automatically update Perl modules' $VERSION with Git?

Let's say, a team of programmers is doing a web application in Perl and uses git to host their code. Now they have a small problem with versioning their modules: Perl::Critic and PBP both recommend a RCS-backed $VERSION variable in code git explicitly recommends against using replaceable revision numbers in code (with good reasoning) ...

Python Git Module experiences?

What are people's experiences with any of the Git modules for Python? (I know of GitPython, PyGit, and Dulwich - feel free to mention others if you know of them.) I am writing a program which will have to interact (add, delete, commit) with a Git repository, but have no experience with Git, so one of the things I'm looking for is ease ...

deploying with capistrano with remote git repo but without git running on production server

I have a remote git repository setup for centralized development within my team. However, the production server that we deploy our applications currently does not have git running on it. We want to use capistrano to deploy our applications how can we set up our deploy recipes to 'pull' from the remote git repositories when deploying? In...

Why am I getting the message, "fatal: This operation must be run in a work tree?"

Just installed git on Windows. I set the GIT_DIR variable to be c:\git\ and verified that this environment variable is maintained by cygwin (i.e. echo $GIT_DIR is what it should be). I went to the folder that I wanted to create the git repository for, let's say c:\www, and then ran: git init git add . Then I get the error: fatal: Th...

What is the difference between a tag and a branch in git?

This is probably an easy question, but I'm having some difficulty understanding how to use tags vs. branches in git. If there's some documentation I should be reading, feel free to just point me to it. The situation I'm in is that I just moved the current version of our code from CVS to Git adn now I'm going to be working on a subset o...

How do I re-play my commits of a local git repo, on top of a project I forked on github.com?

Yes, I know I should have just forked the project from the beginning, but this is what situation I'm in now. :) I have a local git repository, that contains my blog, on my local computer, that has several months of commit history. Originally I simply downloaded the files from this repo: http://github.com/mojombo/mojombo.github.com and ...

How to undo "git commit --amend" done instead of "git commit"

I accidentally amended my previous commit. The commit should have been separate to keep history of the changes I made to a particular file. Is there a way to undo that last commit? If I do something like git reset --hard HEAD^, the first commit also is undone. (i have not yet pushed to any remote directories) ...

git pull - changes from Java

I have a web app that serves some markdown files. What i would like to do is when there is a push to github i would ping my application using a webhook and i want my application to run git pull to retrieve changes. I am sure that no application specific files will change only markdown files in a specific folder. Does any one done somet...

git push failing

I created centralized git repositories on my department's sun solaris server using mkdir /var/git/myapp.git cd /var/git/myapp.git git --bare init last week i did this for 3 of our currently under development applications and pushed the master of these applications to the server git remote add origin ssh://myserver.com/var/git/myapp....

git - removing rails development log

I keep getting the changes made to my development.log in my git repository. My .gitignore file has: log/*.log tmp/**/* doc/api doc/app So I need two things to happen. Get the development.log file out of my current commit (its now too big for the server to receive) Make sure that it doesn't get back in there. Any suggestions? ...

Evil merges in git ?

"man gitglossary" contains this definition of an evil merge: An evil merge is a merge that introduces changes that do not appear in any parent. I am not sure I understand the point the authors are trying to get at. Why is it evil ? ...

What is the advantage of using git submodules over having a repo inside another repo with a gitignore?

We've been looking into git submodules and we are wondering what advantage (if any) is there in having a repository using submodules verses having a repository within another repository with a .gitignore file. Example without submodules: mkdir a cd a git init touch test1.txt echo "b" > .gitignore git add . git commit -m "Adding test1.t...

Revert multiple git commits

Say I have a git repository that looks like this: A -> B -> C -> D -> HEAD I want the head of the branch to point to A, i.e. I want B, C, D, and HEAD to disappear and I want head to be synonymous with A. It sounds like I can either try to rebase (doesn't apply, since I've pushed changes in between), or revert. But how do I revert m...

how do I deploy multiple branches to different directories via git push?

In production, I maintain two sites - beta and release. Each points to a different directory via a soft link (e.g.) beta_public_html -> /home/scott/myapp/trunk/public public_html -> /home/scott/myapp/branches/1.2.3/public I'm a longtime svn user, moving to git. I'm used to deploying via svn update and changing the soft link on a ...

Git merge squash repeatedly

I'm trying to have two branches with binary files in git - one "development" and one "stable". The development branch can have several changes of these files before I want to "release" them to the stable branch (and the stable branch has those files renamed, in case that's relevant). I could do a normal merge, this works fine, but prese...

Referencing TFS 2008 assemblies on a computer without a TFS installation

I'm writing a hook for Git that will let me select workitems from TFS 2008 and inject them into the commit message from Git. I've already written a stub so that I can develop my functionality without referencing TFS 2008. However, when creating the real thing, how do I get a copy of the desired Team Foundation assemblies on my local co...

diff and new empty files

I'm using diff -Naur to send a single patch to a customer, in order to update their snapshot of our repository. I tried using git diff -p to get a single file patch, but apparently it doesn't include new binary files in the patch I know I should have used git-format-patch, but it creates patches which can be only used inside git and I ...