git reset command do?git reset moves the current branch pointer to a specified commit, changing the commit history. It can also modify the staging area and working directory depending on options used.
git revert?git revert creates a new commit that undoes the changes introduced by a previous commit, preserving the commit history.
git reset affect commit history compared to git revert?git reset rewrites commit history by moving the branch pointer backward, potentially removing commits. git revert keeps history intact by adding a new commit that reverses changes.
git reset or git revert?git revert is safer on shared branches because it preserves history and avoids rewriting commits others may have based work on.
git reset modify the working directory and staging area?Yes, depending on the mode (--soft, --mixed, --hard), git reset can change the staging area and working directory along with moving the branch pointer.
git revert do?git revert creates a new commit that reverses changes from a previous commit, preserving history.
git reset moves the branch pointer and can rewrite history.
git revert is safer because it does not rewrite history.
git reset --hard do?--hard resets branch pointer, staging area, and working directory to the specified commit.
git revert remove commits from history?git revert preserves history by adding a new commit that reverses changes.
git reset and git revert in simple terms.git revert instead of git reset?