The title is not very clear. What I actually need to do often is the following:
Let's say I have a development going on with several commits c1,c2,... and 3 branches A,B,C
c1--c2--c3--(B)--c4--(A,C)
Branch A and C are at the same commit.
Now I want branch A to go back where B is, so that it loks like this:
c1--c2--c3--(A,B)--c4--(C...
I would like to make a repo into a bare repo so people can push to it with out big nasty warnings. I could delete it and clone it again... but perhaps there is a more elegant way?
...
I cloned an svn repo with git svn clone ... and now I want to push changes to it. after that I will use this repo to rebase everything and commit back to svn. The problem that pushing to a non-bare repo seems to not be a good idea, and git svn seems unhappy about working with a bare one?
...
Hi,
So I have my local MAMP setup and running a test environment for my projects. When I upload it to the live server for staging I want to keep the passwords and usernames in for example config.php separate from those that are used on the server. This way I won't need to change those each time I push a commit to the server.
I have been...
My .git file has grown to 229Mb and I wondering what the best way to cut down the size is. I know about git gc and have been using it a fair amount. I'm not totally sure about how git works, but I know that there is packaged information in there that I no longer need. Like, I know I no longer need the first five branches saved. Is th...
I have a local git repository a "central" repo at github. I'm working on a part of a project, while a friend is working on a related piece that is in an entirely separate repo, is it possible for me to simply link directly to my friend's repo?
For example, the app is called widgets. I have all my code in widgets/app/mycode and my friend...
I'd like git status to always use the short format:
$ git status --short
M src/meck.erl
M test/meck_tests.erl
?? erl_crash.dump
?? meck_test_module.coverdata
There does not seem to exist a configuration option for this, and git config --global alias.status "status --short" does not work. I haven't managed to create and alias in zsh ...
I need to setup a Kohana dev environment that allows me to make full use of shared module / system classes across separate applications. Each application typically belonging to a different client. I use Git for source control, but am struggling to come up with a clean deployment method that will allow me to pull only those parts of the d...
I have deleted a file or some code in a file sometime in the past. Can I grep in the content (not in the commit messages)?
A very poor solution is to grep the log:
git log -p | grep
However this doesn't return the commit hash straight away. I played around with "git grep" to no avail.
...
I have two servers, let's call them first and second. First one is where the real development is done, and second one should be the replica. What I would like to do is put "git push" in post-receive, but there is one problem. Post-receive is executed as the user doing git push to first server, so I can't chmod 600 ssh key with no pass. W...
I want to change my repository from bazaar to git.
I installed Git (winXP) and tortoise with no problem, I set path variables, etc...
I have initialized my repository with:
$ git init
copied it using
$ cd ..
$ git clone --bare project.git
uploaded it to FTP, and when trying to access:
$ git clone *ftp_address*
Initialized empty ...
I have just performed git add --interactive, so the index version of some files is different than the working-directory versions. Instead of doing git diff --cached, I want to actually dump the contents of each file in the index, but I can't find a command to do that. I should think that there would be something like git show INDEX:fil...
I have a git repository on my server i can ssh over port 443. But now i want to pull from that server and push to it but git gives me connection refused. I think it's connecting over port 22 but i want it to connect over 443. I use tortoiseplink to connect with how can i make it connect through port 443 when pushing or pulling ?
...
I know the question has been asked before how often to commit with a DVCS. All answers have one thing in common--as often as possible. But they're usually something like, after finishing a thought, a user story, getting code that compiles, or passing tests.
I was thinking, given that a DVCS gives you you're own repository, with very chea...
I've been using git along with fugitive.vim to manage code when I'm on windows. However, I've run into a problem. According to the documentation, the :GDiff command should a diff window and allow me to stage only parts of a file. However, when I issue the command in a file with changes, I get the following error message:
Is this a prob...
I've been using the SHA1 hashes of my commits as references in documentation, etc. I've realized that if I need to rewrite those commits, I'll need to create a lookup table to correspond the hashes for the original repo with the hashes for the filtered repo. Since these are effectively UUID's, a simple lookup table would do.
I think t...
RSync is traditionally used to update Gentoo portage tree.
But it's somewhat slow when dealing with a large number of files.
So, I want to try to replace RSync with Git.
I know that Funtoo have Git-based portage tree, but is there a Gentoo-specific official one?
...
I'm trying to update a git repository on github. I made a bunch of changes, added them, committed then attempted to do a git push. The response tells me that everything is up to date, but clearly it's not.
git remote show origin
responds with the repository I'd expect.
Why is git telling me the repository is up to date when there a...
I was working with a friend on a project, and he edited a bunch of files that shouldn't have been edited. Somehow I merged his work into mine, either when I pulled it, or when I tried to just pick the specific files out that I wanted. I've been looking and playing for a long time, trying to figure out how to remove the commits that conta...
Hi,
I have a folder versioned in a git. I want to unversion it, that is to remove the .git meta data, how can I do this?
Thanks
...