From 18905d7cf7ed2e2eb15f7f668c0ecbfcd6b94ec0 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Tue, 3 Dec 2024 13:25:00 -0600 Subject: even with this, go mod tidy still DOWNLOADS STUPID OLD go.sum files --- goDep.redoGoMod.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'goDep.redoGoMod.go') diff --git a/goDep.redoGoMod.go b/goDep.redoGoMod.go index de689fd..8bb8058 100644 --- a/goDep.redoGoMod.go +++ b/goDep.redoGoMod.go @@ -10,6 +10,15 @@ import ( "go.wit.com/log" ) +// remove every go.mod and go.sum +// testing to see where this stuff is coming from +func (repo *Repo) EraseGoMod() { + // unset the go development ENV var to generate release files + if ok, err := repo.strictRun([]string{"rm", "-f", "go.mod", "go.sum"}); !ok { + log.Warn("rm go.mod go.sum failed", err) + } +} + // poor name perhaps. It's because in most of these // repos you can also type "make redomod" to do the same thing // since it's a Makefile task that is also useful to be able to run -- cgit v1.2.3