Tag: git

pip connection failure: cannot fetch index base URL http://pypi.python.org/simple/

I run sudo pip install git-review, and get the following messages: Downloading/unpacking git-review Cannot fetch index base URL http://pypi.python.org/simple/ Could not find any downloads that satisfy the requirement git-review No distributions at all found for git-review Storing complete log in /home/sai/.pip/pip.log Does anyone has any idea about this?

Undo part of unstaged changes in git

How do I undo parts of my unstaged changes in git but keep the rest as unstaged? The way I figured out is: git commit –interactive # Choose the parts I want to delete # Commit the changes git stash git rebase -i master # (I am an ancestor of master) # Delete the line […]

What are the big differences between TFS and Git for source control when using Visual Studio 2013?

There are tons of questions and answers about Git versus TFVC Source Control, but no current answers given the integration of Git into Team Foundation Server/Service that I can find. I’m starting green pasture development using a wide variety of languages (C#, C++, PHP, Javascript, MySSQL) using Visual Studio 2013. In the future, there will […]

Git: How to create patches for a merge?

When I use git format-patch, it doesn’t seem to include merges. How can I perform a merge and then e-mail it to someone as a set of patches? For example, let’s say that I merge two branches and perform another commit on top of the merge: git init echo “initial file” > test.txt git add […]

Git: Ignore files for public repository, but not for private

I’m deploying a Rails app on Heroku (for now) via git, and would also like to have a public version for people to look at. Some files are sensitive and should only be committed and pushed in the “heroku” branch, but not the “public” branch. What is the best way to go about this? (I […]

Reverting to a specific commit based on commit id with Git?

This question already has an answer here: How to revert Git repository to a previous commit? 33 answers

switch git branch without files checkout

Is it possible in git to switch to another branch without checking out all files? After switching branch I need to delete all files, regenerate them, commit and switch back. So checking out files is just a waste of times (and there are about 14000 files – it is a long operation). To make everything […]

git: patch does not apply

I have a certain patch called my_pcc_branch.patch. When I try to apply it, I get following message: $ git apply –check my_pcc_branch.patch warning: src/main/java/…/AbstractedPanel.java has type 100644, expected 100755 error: patch failed: src/main/java/…/AbstractedPanel.java:13 error: src/main/java/…/AbstractedPanel.java: patch does not apply What does it mean? How can I fix this problem?

How to detect a forced update

When a branch history is changed on the remote, you typically get o git@git.server.com:XXXXX/Project.git + efe2e8b…cda0ee7 HEAD -> Ant_Config_processing (forced update) Is there any way to get this (forced update) status using scripting ? The idea is to write an alias that detects it and prompt the user for actions.

Git branches with completely different content

Since Git has the ability to keep track (and keep it clean) of branches with completely different content from each other, in the same repository, some projects (like Git itself) have started to make use of it. Git, for instance, uses one branch for the code itself, while keeping its documentation in a separate branch. […]

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