In Git, is it possible to see the latest diff for a file without specifying a commit? For instance, I’ve got a file called hello.js. It was last modified two commits ago. I could do the following to see those changes: git diff a1b2c3^ hello.js (note the caret, to indicate the “previous” diff). But is […]
Every time I do a git diff, despite lot of commits since the first one, it keeps on giving me these old changes that were committed long time ago to do with file deletions. I deleted an entire folder of stuff in a commit about 7 commits ago, and still on branch or merge, git […]
I was trying to commit files into my source control (Git) as usual, using Xcode 7.0.1 and from a point onwards I keep getting this message, disallowing me to commit changes into my source control: Anyone know how to resolve this?
Okay, I am confused! I have a directory with ~40,000 files, and I created a git repository. I add all the files with: git add . then when I type “git commit” I get a 40,000 line text file that opens, and EVERY line is commented. If I close this file without uncommenting anything, it […]
I created a new git repo on our server and then committed all files. Once those files were committed I then created a new .gitignore file and committed it. I did the two commits in the wrong order because the original commit added around 30k files and the .gitignore file isn’t having any affect. If […]
I have two commits: [branch]: [commit_id] justin: 94943b74ba273a9f4009 jzbranch: 6070aada7b8a690d410b How do I merge the two branches, into jzbranch, and resolve any differences between the two?
My question in similar to git remove commit from a merge but I can’t follow instructions suggested there, since my repository’s history is a little bit different. I’m working on a open-source repository on github. After few months I wanted to update my local repository and I made a useless merge-commit by mistake. The history […]
I’m a beginner with git and having some problems while trying to revert everything to the last time I committed. I don’t mind losing any of the changes I just want to undo everything. I tried this: git revert b78da61000bc049133f4a5f7df6ddb3b6407454f But I’m getting error: Your local changes to the following files would be overwritten by […]
I’m trying to delete, not revert, the last 2 commits on the develop branch of my Git repo. The commits have not been pushed. How would I go about doing this without losing the changes?
Hey, so I’m a complete git newbie here, the most advanced thing I’ve done is just basic pulls/pushes .etc For reasons I don’t understand one of my commits edited a heap of files, including embedded into the file the edits I made since the last commit, for example: foo.txt: bar then if i edited it […]