git

git re-committing reverted commits

I have a project hosted on github. There is a main branch (main-branch) for the code that is deployed in production. Individual projects are branched from main (proj-001, proj-002...). So in the course of a project/deploy.... git checkout main-branch git pull origin main-branch git checkout -b proj-001 (make some edits) git add . git ...

How to undelete a file previously deleted in git's history?

Using Chris's answer on another question I could prepend a snapshot-history to my git repository. Since one of the files is not part of my history but only in the snapshots, the first original commit now also contains the deletion of this file. How can I undo that? At first I thought this was the opposite of How do I remove sensitive fi...

Can tags be automatically moved after a git filter-branch and rebase?

edit The question boils down to "Can git rebase be instructed to rebase tags, too?" But an answer to the original question would also help. Asking How to prepend the past to a git repository? I followed these instructions. <edit>Then I rebased to include a file that was only in the snapshots, see here.</edit> Since history was rewritt...

How to see the file size history of a single file in a git repository?

Is there anyway to see how a file's size has changed through time in a git repository? I want to see how my main.js file (which is the combination of several files and minified) has grown and shrunk over time. ...

Git Remote Repository Check-Out Problem

Hi, I've just started using Git and have never used a versioning system before. I am trying to setup a git repository on my web server and one on my local computer. I am doing the following on the server (I run the commands in a project folder ~/project): git init git add . git commit -am "Initial Commit" Then on my laptop i'm using...

Git usage help, rolling back scenerios

if I made some changes, but didn't do a commit -m "my message, how can I rollback to where I was? if I did a commit -m 'my message' but didn't push to origin, how can I roll back? if I did a git pull origin , now I don't like what I got, how can I roll back to where I was? how can I get a list of what files are at the origin that have c...

Rails "script/plugin" install http://github.com...git hangs on 'git pull'

Whenever I run the rails script/plugin install to install a plugin using git, from github it "hangs". $ script/plugin -v install http://github.com/ryanstout/blog_kit.git It "hangs". the -v gives me the following output: Plugins will be installed using http git init Initialized empty Git repository in /home/XXX/vendor/plugins/blog_ki...

How to update my local Webkit repository using git.

Hi, I have download a git repository locally using this: git clone git://git.webkit.org/WebKit.git WebKit I am using that a own experiment (not intended to push the changes back to webkit.org). So I made some changes and do then 'git commit'. But I would like to find out what is the best way for me to update my Webkit repository (as...

How can I sanely approach version control and Core Data models?

When we put Core Data model files under version control with git, we always have a horrible time merging changes - the only sure fire way we've found to avoid having to merge in changes by hand is to communicate among the team to block off access to the model while one person makes their necessary changes and pushes, then the next person...

Moving a .git Directory

I have a repository that I created early in the learning curve of a project. As I've learned more, I've realized that this is creating problems because some of the files I want tracked aren't required in the compiled source. What I'd like to do is create a new "project" parent directory, move the existing source directory into that paren...

Separate Web Server from Client App in Git?

I am fairly new to Git and am curious if anyone sees an issue with having the code for both my web application and client (iPhone) app under the same Git project. I was thinking of creating a folder structure for git like the following: MyProject ServerSide_Code iPhone_Code Should these be broken out into separate projects? C...

Git svn rebase : checksum mismatch

Hello, I have a problem when I try to do a git svn rebase on my repository. It displays : Checksum mismatch: code/app/meta_appli/app_info.py expected: d9cefed5d1a630273aa3742f7f414c83 got: 4eb5f3506698bdcb64347b5237ada19f I searched a lot but haven't found a way to solve this problem. If anybody knows, please share your knowledg...

How can I add a specific folder from a git repo as a git submodule?

I have a git repo and I want to add a submodule to it. Problem is, the submodule exists as a folder inside another repo. Can I add only that folder as a submodule? ...

migrate svn to subdirectory of git

I'd like to replace my svn repository with git. Unfortunately I can't do this in one shot and to cut a long story short, I need to move an svn repository, with history, into a subdirectory of a pre-existing git repository. So I currently have: svn: svn1/ svn2/ git: git1/ .git/ gita/ And I want: svn: svn1/ git: git1/ .git/ ...

Git question: ignoring files inside repository

I erroneously added some local project files to a git repository and committed/pushed them. I'd like to delete these files from the remote repository, keep them locally, and ignore them for future commits/pushes. What's the best way to go about this? ...

Should I have to add files to git every time I want to commit?

I'm new to git, coming from SVN world. So far, it seems a lot more useful, but I am still working out the kinks. Currently, my workflow is like this: make changes > git add . > git commit > enter log message What I don't understand is why I seem to have to add all of my files before I commit. They are under version control already? ...

Split two or more git branches into separate subdirectories of one repo?

Hey folks, This question is somewhat similar to How to combine two branches from two different repositories in a single repository?. However, I want to combine two branches from the same repository into one branch, but in separate subdirectories. So, starting with one repo that has two branches: /appFoo -MasterBranch -OtherVersion...

Find the parent branch of a branch

Hi all, Lets say I have the following local repository with a commit tree like this: master --> a \ \ develop c --> d \ \ feature f --> g --> h master is my this is the latest stable release code, develop is my this is the 'next' release code, and feature is a new...

git: how to retrieve all files as of a certain date

I'm sure this can be done (?) (in clearcase it would be quite simple). ...

git, Deleted a file my mistake, how to get from origin master?

I deleted a file on my desktop by mistake, how can I get it from the remote master? ...