X-Git-Url: http://www.git.cypherpunks.ru/?a=blobdiff_plain;f=run.go;h=40fad74af0f20f98dc517020faca88c86df57359;hb=14398260feaf14dac68b9bdb1c810ccba7d1e768;hp=824f6c255ee45a0a165577c2d56f706d9627ebcd;hpb=679764f6a0162617a3e218384a36baf44179dd4b;p=goredo.git diff --git a/run.go b/run.go index 824f6c2..40fad74 100644 --- a/run.go +++ b/run.go @@ -1,6 +1,6 @@ /* goredo -- redo implementation on pure Go -Copyright (C) 2020 Sergey Matveev +Copyright (C) 2020-2021 Sergey Matveev This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -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