Tag: git

how to add colour diff in git send-email

I am using git send-email command, but the diff patch is not colored. If I try git send-email -1 –color it send ANSI colour code in email and unformatted text. I want to be able to mail color diff patch.

Shell script change directories, run git branch to find the branch I'm in and then assign the output to a variable

This is more of a shell scripting question than a git problem. I have a directory structure that is along the lines of: /projects/Project1/package1 /projects/Project1/package2 /projects/Project1/package3 etc… I am using git for each of my packages but I am trying to run a script that will pull the latest changes from the remote for each […]

How to apply a serie of patches with git

It is convenient to send sets of patches using git send-email. But once I received a set of patch, how to apply them? Especially, how to apply them in right order? If I save them in a separate Maildir and I give this Maildir in argument to git am, patches are not applied in right […]

Propagating changes to git subtrees using read_tree without network connection

I am using read-tree in git to include ProjectA in ProjectB. I have both projects cloned to my computer. /ProjectA /ProjectB /remote/ProjectA When I am making changes to ProjectA from inside ProjectB (/ProjectB/remote/ProjectA), currently what I do to propagate all the changes is the following: 1) commit project B (from ProjectB’s root directory) : git […]

deploy to production from master or hotifx?

We are adopting Git on the company after some years of SVN usage. The git flow suits our needs very well with the master/hotfix/develop/release branches. So far everything is going well, apart from a conundrum. Our project is a Java app for weblogic, we produce a WAR file on the project build. The context is: […]

error in git push over smart http?

i have set up a git server using smart-http and i could achieve read access to do clone or pull from the repository, but i am unable to achieve write access to push the changes, so when i give git push origin master, i am getting the error as, error: Cannot access URL http://username:password@localhost/, return […]

Gitlab 6.4 not pushing to correct repository directory

I’m in the process in migrating from GitLab 6.0 on Ubuntu 12.04 to GitLab 6.4.3 on CentOS 6.5. I followed these instructions and everything is up, but I have two issues: When creating a new project and trying to push to it via git push -u origin master I get the error fatal: asc/project-name.git does […]

cant push to bitbucket forked repo

Here is my situation: I am a newbie to git and for learning purpose: I (User A) created a repository in bitbucket. Then cloned the repo and created a readme file and pushed it successfully to remote. I signed up as another user, lets say user B on bitbucket. As user B, I have a […]

git – Can I have public preferred config settings for my repo?

I’d like to do something like force anyone from committing trailing whitespace to my branch by showing them an error rather than allow the commit. I know I can add something to .git/config but I’m interested in doing something so that when the repo is cloned the file is still there like .gitignore. Does git […]

How to make git mergetool aware of diff markers

Git mergetool is a wonderful command. However, I find very annoying that it shows all the diffs with respect to the BASE (possibly hundreds), rather than the conflicts only (often just a couple). This answer (Tip One) provides a solution… which however is manual (take the output of git merge, create three different files with […]

Git Baby is a git and github fan, let's start git clone.