aboutsummaryrefslogtreecommitdiffhomepage
path: root/magefile.go
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <[email protected]>2017-12-07 22:38:54 +0100
committerBjørn Erik Pedersen <[email protected]>2017-12-07 22:38:54 +0100
commit31535261610b34131c68ec760db8b29cac1548dd (patch)
tree37ed745c20e658ae1a65f84e2db451b1b9ba9df7 /magefile.go
parentfdbef2a81c619930233b6f85682fd88b7b870f78 (diff)
downloadhugo-31535261610b34131c68ec760db8b29cac1548dd.tar.gz
hugo-31535261610b34131c68ec760db8b29cac1548dd.zip
mage: Do not run Go Fmt check on Go tip
Diffstat (limited to 'magefile.go')
-rw-r--r--magefile.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/magefile.go b/magefile.go
index 31da50686..d74aaa3ee 100644
--- a/magefile.go
+++ b/magefile.go
@@ -127,6 +127,9 @@ func TestRace() error {
// Run gofmt linter
func Fmt() error {
+ if isGoTip() {
+ return nil
+ }
pkgs, err := hugoPackages()
if err != nil {
return err
@@ -256,3 +259,7 @@ func CheckVendor() error {
}
return nil
}
+
+func isGoTip() bool {
+ return strings.Contains(runtime.Version(), "devel")
+}