git discard last commit keep changes code example Example: undo last commit but keep changes git reset @~