From 8d5585b7ef0cd458d9e005abdf5ce7fb2f0c5e47 Mon Sep 17 00:00:00 2001 From: Sergey Matveev Date: Tue, 15 Dec 2020 15:17:48 +0300 Subject: [PATCH] Explicitly remove possibly existed but now empty target result --- run.go | 1 + 1 file changed, 1 insertion(+) diff --git a/run.go b/run.go index 824f6c2..512418b 100644 --- a/run.go +++ b/run.go @@ -507,6 +507,7 @@ func runScript(tgtOrig string, errs chan error, traced bool) error { // Do we need to ifcreate it, of ifchange with renaming? if fd == nil { + os.Remove(path.Join(cwdOrig, tgt)) err = ifcreate(fdDep, tgt) if err != nil { goto Finish -- 2.44.0