summaryrefslogtreecommitdiffstats
path: root/pkg/commands/git.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/commands/git.go')
-rw-r--r--pkg/commands/git.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/pkg/commands/git.go b/pkg/commands/git.go
index dbd9087c2..1b798990c 100644
--- a/pkg/commands/git.go
+++ b/pkg/commands/git.go
@@ -905,3 +905,8 @@ func (c *GitCommand) RemoveUntrackedFiles() error {
func (c *GitCommand) ResetHardHead() error {
return c.OSCommand.RunCommand("git reset --hard HEAD")
}
+
+// ResetSoftHead runs `git reset --soft HEAD`
+func (c *GitCommand) ResetSoftHead() error {
+ return c.OSCommand.RunCommand("git reset --soft HEAD")
+}