Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo N Feliciano <FelicianoTech@gmail.com>2020-07-24 19:52:31 +0300
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-07-30 09:44:51 +0300
commit21dbfa1f111ca2f066e06af68f267932ce6cf04f (patch)
tree46854aab0918619753f5420df9123b48042f9179 /magefile.go
parente5591e89d3a71560b70c5f0ded33f2c9465ffe5a (diff)
mage: Add uninstall target
Diffstat (limited to 'magefile.go')
-rw-r--r--magefile.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/magefile.go b/magefile.go
index 9b9dbd3d5..335bcf1e5 100644
--- a/magefile.go
+++ b/magefile.go
@@ -57,6 +57,11 @@ func Install() error {
return sh.RunWith(flagEnv(), goexe, "install", "-ldflags", ldflags, "-tags", buildTags(), packageName)
}
+// Uninstall hugo binary
+func Uninstall() error {
+ return sh.Run(goexe, "clean", "-i", packageName)
+}
+
func flagEnv() map[string]string {
hash, _ := sh.Output("git", "rev-parse", "--short", "HEAD")
return map[string]string{