Tag: repository

Not all files added to Git repository

I’ve created repo, with standard commands git init git add . git remote add origin ssh://trololo.lo/~/git_rep.git git commit -a -m “trololo” git push origin master After that i’ve created empty repo on another machine, pulled origin. Some files are missing, any idea why and what I should do?

Git How to Recursively Delete Files and Folders?

I accidentally uploaded my bin, classpath, and a couple other files to my git which I had previously soft deleted. What command can I use to go through all my commits and delete certain files from my remote files only, not local.

Can Git or Mercurial be set to bypass the local repository and go straight to the central one?

Using Git or Mercurial, if the working directory is 1GB, then the local repository will be another 1GB (at least), residing normally in the same hard drive. And then when pushed to a central repository, there will be another 1GB. Can Git or Mercurial be set to use only a working directory and then a […]

How to handle git with two repositories

This is probably a novice question, so I apologize for my daftness ahead of time. I am deploying to Heroku, and managing my repository through github. So I have two git accounts with one code base. My .git/config looks like this : [core] repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true […]

Setting up git after fresh install

I’m planning to install mountain lion on my macbook pro and erase everything in my hard drive too. I currently have git installed with a few repos and my ssh key is connected with remote repos as well. I’m not sure how to go about restoring everything after the fresh install of osx. I am […]

Combine Separate Git Repository Branches

I have two separate git repositories. One is mine, and has “Branch A”, the other was developed by someone else and has “Branch B”. They both have the same master branch. How do I import his branch inside my git repository? So I want the result to be: $ git branch Branch A Branch B […]

GIT: Make a file unique for all branches

I need to add some global descriptions ( like howto use the specific repository and other instructions) to a git repository. Is there a way to assure, that changes can for example only be tracked on master branch and unique for all other branches? Thank you and best regards, M.S.

Transferring history of CVS to GIT

We have the code base using CVS for long time. And now we are considering to move to git. The sources can be moved to GIT, no problem. But I want to know, how the history or the changes in CVS can be moved to the git. For example, assume in CVS, 1st day there […]

pushing from a bare repository to another bare repository

We are looking to have a Git architecture like the following. I have created two bare repositories for these. //production/repo/MyProject.git (prod-repo) //dev/repo/MyProject.git (dev-repo) After pushing my code to the dev-repo and testing it, I want to push all the changes to prod-repo. Obviously I won’t have a working directory on either of these machines? How […]

Unique identifier for file in Git Repository

There exists an unique identifier for files in a Git Repository? This unique identifier must be the same after some commits (modifying file), after reneming and moving that file. There it exists? I tried git ls-files –debug but I didn’t find an unique identifier with the characteristics listed above.

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