]> git.sesse.net Git - skvidarsync/commitdiff
If run with --daemon, start a single run even if there is no marker, because the...
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 29 Oct 2023 23:01:11 +0000 (00:01 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 29 Oct 2023 23:01:11 +0000 (00:01 +0100)
bin/sync.pl

index 4487fb45dcd6e5d8a76748d7d2534c1bdd09edac..e1840f271de02246c301650ed44d16d23a61ea41 100644 (file)
@@ -593,6 +593,10 @@ sub run {
 }
 
 if ($#ARGV >= 0 && $ARGV[0] eq '--daemon') {
+       # Start with a single, forced run.
+       unlink("/srv/skvidar-slack.sesse.net/marker");
+       run();
+
        while (1) {
                if (!unlink("/srv/skvidar-slack.sesse.net/marker")) {
                        unless ($!{ENOENT}) {