summaryrefslogtreecommitdiff
path: root/internal/queue
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2024-12-10 22:01:27 +0200
committerPaul Buetow <paul@buetow.org>2024-12-10 22:01:27 +0200
commita5529938536f7a530f0c55e5a82b16a4c80af5b4 (patch)
tree8c76b7190872174bc9dea434f8c3af758d0ffa28 /internal/queue
parentc0e0e1ff4905af70a4f113eb9c2e0d94f18b2436 (diff)
fix
Diffstat (limited to 'internal/queue')
-rw-r--r--internal/queue/queue.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/internal/queue/queue.go b/internal/queue/queue.go
index 80f6dcd..4a894dc 100644
--- a/internal/queue/queue.go
+++ b/internal/queue/queue.go
@@ -52,7 +52,7 @@ func queueEntries(args config.Args) error {
destPath := fmt.Sprintf("%s/db/%s.%s.queued", args.GosDir, filepath.Base(en.Path), timestamp.Now())
if args.DryRun {
- colour.Infoln("Not queueing entry", en.Path, "to", destPath, "as dry-run mode enabled")
+ _, _ = colour.Infoln("Not queueing entry", en.Path, "to", destPath, "as dry-run mode enabled")
continue
}
if err := oi.Rename(en.Path, destPath); err != nil {
@@ -89,7 +89,7 @@ func queuePlatforms(args config.Args) error {
return err
}
if share.Excluded(platform.String()) {
- colour.Infoln("Not queueing entry", en, "to platform", platform, "as it is excluded")
+ _, _ = colour.Infoln("Not queueing entry", en, "to platform", platform, "as it is excluded")
continue
}
if err := queuePlatform(en, args.GosDir, platform); err != nil {
@@ -102,7 +102,7 @@ func queuePlatforms(args config.Args) error {
// Keep queued items in trash for a while.
trashPath := filepath.Join(trashDir, strings.TrimSuffix(filepath.Base(en.Path), ".queued")+".trash")
- colour.Infof("Trashing %s -> %s", en.Path, trashPath)
+ _, _ = colour.Infof("Trashing %s -> %s", en.Path, trashPath)
fmt.Print("\n")
if err := oi.EnsureParentDir(trashPath); err != nil {
return err
@@ -124,11 +124,11 @@ func queuePlatform(en entry.Entry, gosDir string, platform platforms.Platform) e
// Entry already posted platform?
if oi.IsRegular(postedFile) {
- colour.Infoln("Not re-queueing", destPath, "as", postedFile, "already exists")
+ _, _ = colour.Infoln("Not re-queueing", destPath, "as", postedFile, "already exists")
return nil
}
- colour.Infoln("Queuing", en.Path, "->", destPath)
+ _, _ = colour.Infoln("Queuing", en.Path, "->", destPath)
return oi.CopyFile(en.Path, destPath)
}
@@ -143,7 +143,7 @@ func deleteFiles(path, suffix string, olderThan time.Time) error {
return err
}
if fileInfo.ModTime().Before(olderThan) {
- colour.Infoln("Cleaning up", filePath)
+ _, _ = colour.Infoln("Cleaning up", filePath)
err := os.Remove(filePath)
if err != nil {
return err