Bring back local changes after a checkout

Is there any way to redo changes in the working directory after checking them out? I just ssh’d into a server I hadn’t been on in a while and saw that there were unstaged changes in the index. I assumed that this was just scratch work I had done last time, but figured because I […]

Git don't merge specific files (or even lines) when merging branches

First of all, I have a feeling that this has been covered somewhere else, however I was unable to find it despite searching both SO and Google. If this is indeed a duplicate please feel free to mark it as so My git-based website is currently composed to two branches – Development and Production. (I’m […]

Git bisect for a gem dependency?

I have Ruby gem with tests, and it has a dependency on another gem. Recently there was a new release of that other gem, which broke my gem’s test suite due to a change in behaviour. I know which minor version bump of the other gem is to blame, but I want to find out […]

using git to selectively push certain files but then I can't checkout another branch

I changed a few files in my local branch. I only want to push one file to origin. So I added, committed, and merged and pushed only that file to the origin. Now, I want to checkout another branch to do work in there. But git says that since I have uncommitted modified files I […]

Two branches with shared code – how to do that in git?

I’ve a problem with organising my Android app’s repository. My client wants to have two language versions but unfortunately the translations differ so much that I have to adjust the layout files quite heavily for one language. App is still in development so any fixes to the actual code should be present in both language […]

Allow Github Organization to read repository

I have created a repository inside an Organization, and want to give all members of that organization access to read/fork the repository without making it public. Is that possible? I know we could add all members manually to a team called “All members” and then give that team access. But the organization is large, with […]

git fatal: repository not found remote access for Internal TFS server

We have an internal hosted instance of Team Foundation Server 2013 with many projects that use GIT source control. If I use Visual Studio 2015, I am able to clone, push, pull, etc. with no problem. However when I try to interact with the server using the git command line, git is unable to communicate […]

Pull from remote branch, but do not include the whole history

I’m using eZ Platform open source CMS. The way you start the project is to create it with composer. After some work, new version comes out and the only way to update it is to git pull from github repository, merge it and resolve conflicts. The whole process is straight forward. Except there is a […]

git pull ignores current work directory in shell script

I’m trying to get some sort of auto-deployment working. My current post-update hook looks like follows: #!/bin/sh for ref in $@ do if [ $ref = “refs/heads/master” ] then echo “Deploying $ref to dev-domain” cd ~/www/dev-domain echo “” > system/lock if ! git pull –ff-only then echo “Failed to pull” exit fi if ! system/migrateDatabase […]

How to connect one code into two git repositories?

I have an iOS project in my Xcode. I want to push my changes into two separate git repositories. (One is repository in our local network and the other one is a repository in my servers on Internet). Is there any options to connect the code to two repositories?

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