diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2018-08-22 09:28:19 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-22 09:28:19 +1000 |
commit | 584d6b241cc1d4cacb8bda45babbfd148725dee4 (patch) | |
tree | d894e8368ebf8f2c15f991182e5bb285f0bb253c /pkg/commands | |
parent | 4d635cd1cd7ed1a32e516d3d93a0449d3c3a130e (diff) | |
parent | 37681627ab46bc97af6cffcc812dadfe98c0852b (diff) |
Merge pull request #198 from antham/fix-various-errors
Fix various errors reported by goreportcard
Diffstat (limited to 'pkg/commands')
-rw-r--r-- | pkg/commands/os.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pkg/commands/os.go b/pkg/commands/os.go index 9756d619d..18ff93cc6 100644 --- a/pkg/commands/os.go +++ b/pkg/commands/os.go @@ -175,7 +175,8 @@ func (c *OSCommand) Unquote(message string) string { return message } -func (C *OSCommand) AppendLineToFile(filename, line string) error { +// AppendLineToFile adds a new line in file +func (c *OSCommand) AppendLineToFile(filename, line string) error { f, err := os.OpenFile(filename, os.O_APPEND|os.O_WRONLY|os.O_CREATE, 0600) if err != nil { return err |