From c98a9c7b25259f0985219fbcc59065de085d373f Mon Sep 17 00:00:00 2001
From: "Rob Swindell (on Debian Linux)" <rob@synchro.net>
Date: Sun, 24 Sep 2023 13:17:47 -0700
Subject: [PATCH] Add -readd option to mark any updated existing files as
 newly-uploaded

---
 exec/addfiles.js | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/exec/addfiles.js b/exec/addfiles.js
index 4e7979c6e0..76f9263029 100755
--- a/exec/addfiles.js
+++ b/exec/addfiles.js
@@ -59,6 +59,7 @@ for(var i = 0; i < argc; i++) {
 			writeln("                  (default: " + default_excludes.join(',') + ")");
 			writeln("  -diz            always extract/use description in archive");
 			writeln("  -update         update existing file entries (default is to skip them)");
+			writeln("  -readd          re-add existing file entries (so they appears as newly-uploaded");
 			writeln("  -date[=fmt]     include today's date in description");
 			writeln("  -fdate[=fmt]    include file's date in description");
 			writeln("  -adate[=fmt]    include newest archived file date in description");
@@ -246,7 +247,7 @@ for(var d = 0; d < dir_list.length; d++) {
 				file.md5 = hash.md5;
 				file.sha1 = hash.sha1;
 			}
-			if(!filebase.update(file.name, file, options.diz)) {
+			if(!filebase.update(file.name, file, options.diz, options.readd)) {
 				alert("Error " + filebase.last_error + " updating " + file.name);
 			} else {
 				writeln("Updated " + file.name);
-- 
GitLab