mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-30 17:24:59 +00:00
fix: Show undo hint only if current HEAD is not the same as commit_before_message
This commit is contained in:
parent
82679ee66b
commit
1a3f4041f7
1 changed files with 3 additions and 2 deletions
|
@ -1661,7 +1661,8 @@ class Coder:
|
||||||
if self.show_diffs:
|
if self.show_diffs:
|
||||||
self.commands.cmd_diff()
|
self.commands.cmd_diff()
|
||||||
|
|
||||||
def show_undo_hint(self):
|
def show_undo_hint(self, commit_hash):
|
||||||
|
if self.commit_before_message != self.repo.repo.head.commit.hexsha:
|
||||||
self.io.tool_output(f"You can use /undo to revert and discard commit {commit_hash}.")
|
self.io.tool_output(f"You can use /undo to revert and discard commit {commit_hash}.")
|
||||||
|
|
||||||
def dirty_commit(self):
|
def dirty_commit(self):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue