From: Simon Ruderich Date: Tue, 20 Apr 2021 09:44:16 +0000 (+0200) Subject: remote: go fmt X-Git-Url: https://ruderich.org/simon/gitweb/?a=commitdiff_plain;h=a8f56fb33726b836ce853d0606ab0d173f5444f8;p=safcm%2Fsafcm.git remote: go fmt --- diff --git a/cmd/safcm-remote/sync/commands_test.go b/cmd/safcm-remote/sync/commands_test.go index 1c53418..9de9bd5 100644 --- a/cmd/safcm-remote/sync/commands_test.go +++ b/cmd/safcm-remote/sync/commands_test.go @@ -68,7 +68,7 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo; env | grep SAFCM_", + Cmd: "echo; env | grep SAFCM_", }, }, }, @@ -111,7 +111,7 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo; env | grep SAFCM_", + Cmd: "echo; env | grep SAFCM_", }, }, }, @@ -143,7 +143,7 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo hi; false", + Cmd: "echo hi; false", }, }, }, @@ -187,7 +187,7 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo hi; false", + Cmd: "echo hi; false", }, }, }, @@ -219,16 +219,16 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group1", - Cmd: "echo first", + Cmd: "echo first", }, { OrigGroup: "group2", - Cmd: "echo second", + Cmd: "echo second", }, { OrigGroup: "group3", - Cmd: "false", + Cmd: "false", }, { OrigGroup: "group4", - Cmd: "echo third", + Cmd: "echo third", }, }, }, @@ -342,7 +342,7 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo; env | grep SAFCM_", + Cmd: "echo; env | grep SAFCM_", }, }, }, @@ -461,7 +461,7 @@ func TestSyncCommands(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo; env | grep SAFCM_", + Cmd: "echo; env | grep SAFCM_", }, }, }, diff --git a/cmd/safcm/config/commands.go b/cmd/safcm/config/commands.go index 72a28fd..569cdbe 100644 --- a/cmd/safcm/config/commands.go +++ b/cmd/safcm/config/commands.go @@ -47,7 +47,7 @@ func LoadCommands(group string) ([]*safcm.Command, error) { for _, x := range cmds { res = append(res, &safcm.Command{ OrigGroup: group, - Cmd: x, + Cmd: x, }) } return res, nil diff --git a/cmd/safcm/sync_sync_test.go b/cmd/safcm/sync_sync_test.go index f100f35..e96fe14 100644 --- a/cmd/safcm/sync_sync_test.go +++ b/cmd/safcm/sync_sync_test.go @@ -139,11 +139,11 @@ func TestHostSyncReq(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo command one", + Cmd: "echo command one", }, { OrigGroup: "group", - Cmd: "echo -n command two", + Cmd: "echo -n command two", }, }, }, @@ -244,11 +244,11 @@ func TestHostSyncReq(t *testing.T) { Commands: []*safcm.Command{ { OrigGroup: "group", - Cmd: "echo command one", + Cmd: "echo command one", }, { OrigGroup: "group", - Cmd: "echo -n command two", + Cmd: "echo -n command two", }, }, }, diff --git a/types.go b/types.go index 37c0d4a..cca638e 100644 --- a/types.go +++ b/types.go @@ -108,7 +108,7 @@ type File struct { type Command struct { OrigGroup string // group which provided this command - Cmd string + Cmd string } type FileChange struct {