From 8961a3794cc2f5bc31b592367e82aa1766f24bbd Mon Sep 17 00:00:00 2001 From: Joseph Richey Date: Tue, 7 Aug 2018 13:54:45 -0700 Subject: [PATCH] plugins/go: Simplify/fix recursive golang format (#7027) Per the [`go` command specification](https://golang.org/cmd/go/#hdr-Package_lists), the `...` wildcard matches the empty string. This makes commands like `go . ./...` unnecessary: they should use `go ./...`. This also fixes a bug with the `gofa` shortcut, where it would emit an error if called from a directory containing no go source files (but having subdirectories that _did_ contain go files). --- plugins/golang/golang.plugin.zsh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/golang/golang.plugin.zsh b/plugins/golang/golang.plugin.zsh index d5c78ce6c..64c80e864 100644 --- a/plugins/golang/golang.plugin.zsh +++ b/plugins/golang/golang.plugin.zsh @@ -184,7 +184,7 @@ alias gob='go build' alias goc='go clean' alias god='go doc' alias gof='go fmt' -alias gofa='go fmt . ./...' +alias gofa='go fmt ./...' alias gog='go get' alias goi='go install' alias gol='go list'