]> Lady’s Gitweb - Beorn/commitdiff
Be more precise checking for date‐named directories 0.2.1
authorLady <redacted>
Wed, 3 May 2023 01:50:34 +0000 (18:50 -0700)
committerLady <redacted>
Wed, 3 May 2023 01:50:34 +0000 (18:50 -0700)
Otherwise the script will pick up on any directory which _contains_ a
date, not just those which _are_ one.

build.js

index aaa13ed814f2b3f5fcca481e66103f0b52e3d33e..9ae91c9f68f5702518d1662b67eaf87aef9b86ce 100755 (executable)
--- a/build.js
+++ b/build.js
@@ -1018,7 +1018,7 @@ await (async () => { // this is the run script
   ) {
     // Iterate over each directory and process the ones which are
     // dates.
-    if (!isDirectory || !/[0-9]{4}-[0-9]{2}-[0-9]{2}/u.test(date)) {
+    if (!isDirectory || !/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/u.test(date)) {
       // This isn’t a dated directory.
       continue;
     } else {
This page took 0.025482 seconds and 4 git commands to generate.