diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2019-03-18 20:44:33 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2019-03-23 13:26:17 +1100 |
commit | ff97ef7b94b5ccfda1d8b98b0a7e21a779309fcc (patch) | |
tree | 3eea28e8b5e635e8b23138ecd9a5cdc7fe0c4e8a /pkg/commands/os.go | |
parent | a2c780b085b4b5fecf387d4f848d562494ab51cc (diff) |
support discarding unstaged changes
Diffstat (limited to 'pkg/commands/os.go')
-rw-r--r-- | pkg/commands/os.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pkg/commands/os.go b/pkg/commands/os.go index 9e0967cba..1fb8e8da6 100644 --- a/pkg/commands/os.go +++ b/pkg/commands/os.go @@ -255,9 +255,9 @@ func (c *OSCommand) CreateTempFile(filename, content string) (string, error) { return tmpfile.Name(), nil } -// RemoveFile removes a file at the specified path -func (c *OSCommand) RemoveFile(filename string) error { - err := os.Remove(filename) +// Remove removes a file or directory at the specified path +func (c *OSCommand) Remove(filename string) error { + err := os.RemoveAll(filename) return WrapError(err) } |