What do you want to save?
Add Code snippet
New code examples
-
Shell/Bash 2022-02-02 05:15:42
revert to commit git
# This will destroy any local modifications. # Don't do it if you have uncommitted work you want to keep. git reset --hard 0d1d7fc32 # Alternatively, if there's work to keep: git stash git reset --hard 0d1d7fc32 git stash pop # This saves the modificatio... Add solution -
Shell/Bash 2022-01-31 04:05:27
git rebase conflict
Resolving merge conflicts after a Git rebase When you perform a git rebase operation, you're typically moving commits around. Because of this, you might get into a situation where a merge conflict is introduced. That means that two of your commits modifi... Add solution -
Shell/Bash 2022-01-25 01:55:43
> git checkout -q error: you need to resolve your current index first
# CONFLICT (content): Merge conflict in path/to/file # open the file in an editor of your choice $ vim /path/to/file_with_conflict # repeat for every file that has a conflict and then $ git commit -a -m 'commit message' Add solution -
Shell/Bash 2021-10-20 10:52:04
git Automatic merge failed; fix conflicts and then commit the result
# Step 1: # Navigate into the local Git repository that has the merge conflict. cd REPOSITORY-NAME # Step 2: # Generate a list of the files affected by the merge conflict. # In this example, the file styleguide.md has a merge conflict. git status ... Add solution -
Other 2021-09-15 14:24:02
how to handle merge conflicts
# Step 1: # Navigate into the local Git repository that has the merge conflict. cd REPOSITORY-NAME # Step 2: # Generate a list of the files affected by the merge conflict. # In this example, the file styleguide.md has a merge conflict. git status ... Add solution -
Shell/Bash 2021-09-08 21:28:03
Git
Git has been the standard, it is more transparent in operations then other source control systems and allows more flexibility in terms of scipting and automating, logging etc. Git is also great for beginners fostering a solid understanding of principals... Add solution -
Shell/Bash 2021-08-30 09:59:01
how to revert branch to old commit
# This will destroy any local modifications. # Don't do it if you have uncommitted work you want to keep. git reset --hard 0d1d7fc32 # Alternatively, if there's work to keep: git stash git reset --hard 0d1d7fc32 git stash pop # This saves the modificatio... Add solution -
Shell/Bash 2021-08-28 02:07:01
how to revert back to previous commit in git
# This will destroy any local modifications. # Don't do it if you have uncommitted work you want to keep. git reset --hard 0d1d7fc32 # Alternatively, if there's work to keep: git stash git reset --hard 0d1d7fc32 git stash pop # This saves the modificatio... Add solution