mirror of
https://github.com/Bhupesh-V/ugit.git
synced 2026-09-10 07:26:20 -04:00
Merge pull request #52 from thecesrom/fix/undo-initial-commit-printf-success
fix: `printf` command when undoing initial commit
This commit is contained in:
commit
cd5960b2f4
2
ugit
2
ugit
|
|
@ -64,7 +64,7 @@ undo_git_commit() {
|
|||
# This will not delete the files from your working directory
|
||||
if [[ "$last_commit" == "$initial_commit" ]]; then
|
||||
if git update-ref -d HEAD && git rm --cached -rf . > /dev/null 2>&1; then
|
||||
printf "%s\nInitial commit: $initial_commit successfully undone. Commit state is clean."
|
||||
printf "%s\n" "Initial commit: $initial_commit successfully undone. Commit state is clean."
|
||||
else
|
||||
perror "Error: Failed to revert initial commit"
|
||||
exit
|
||||
|
|
|
|||
Loading…
Reference in a new issue