summaryrefslogtreecommitdiff
path: root/doIncoming.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-10-14 11:38:21 -0500
committerJeff Carr <[email protected]>2025-10-14 11:39:02 -0500
commitb0b0a32365d607a10fb7152419a2c1f34ba4df14 (patch)
treee852e4559a3ad1d4ec207cf2ea44bb56e8edc2ce /doIncoming.go
parentb73be5b5b19c19c6d8f5de8a4adca783144e9659 (diff)
bad idea. something went wrongv0.0.24
Diffstat (limited to 'doIncoming.go')
-rw-r--r--doIncoming.go7
1 files changed, 5 insertions, 2 deletions
diff --git a/doIncoming.go b/doIncoming.go
index 636aa14..636ff18 100644
--- a/doIncoming.go
+++ b/doIncoming.go
@@ -69,11 +69,14 @@ func doIncoming(pb *zoopb.Packages) (string, error) {
log.Printf("different checksums: %s %s\n", path, newfilename)
log.Printf("md5sum old %x vs new %x\n", md5.Sum(olddata), md5.Sum(newdata))
}
+ if argv.Force {
+ moveFileToBroken(newfilename)
+ // os.Rename(path, newfilename)
+ // log.Printf("%s moved incoming oldname %s newname: %s\n", packageName, path, newfilename)
+ }
// return "file already exists. use --force to replace", errors.New("duplicate .deb in incoming/")
me.sh.GoodExit("file already exists. TODO: fix this to use --force to replace")
}
- os.Rename(path, newfilename)
- log.Printf("%s moved incoming oldname %s newname: %s\n", packageName, path, newfilename)
incount += 1
if incount > 100 {
me.sh.GoodExit("file moved")