]> Lady’s Gitweb - Beorn/commitdiff
Switch sorting order 0.2.3
authorLady <redacted>
Sun, 7 May 2023 04:27:05 +0000 (21:27 -0700)
committerLady <redacted>
Sun, 7 May 2023 04:27:05 +0000 (21:27 -0700)
Used to be ascending, but descending is more typical.

build.js

index b6ab4867b51373eaec63c6ef7b5f975018238329..76f2083baccc1dd0dcc0cc61f0533b533521d829 100755 (executable)
--- a/build.js
+++ b/build.js
@@ -1019,7 +1019,7 @@ await (async () => { // this is the run script
       isDirectory && /^[0-9]{4}-[0-9]{2}-[0-9]{2}$/u.test(date)
     ).sort(({ name: a }, { name: b }) =>
       // Sort the directories.
-      a < b ? -1 : a > b ? 1 : 0
+      a < b ? 1 : a > b ? -1 : 0
     )
   ) {
     // Iterate over each dated directory and process its entries.
@@ -1031,7 +1031,10 @@ await (async () => { // this is the run script
         isDirectory &&
         //deno-lint-ignore no-control-regex
         !/[\x00-\x20\x22#%/<>?\\^\x60{|}\x7F]/u.test(entryName)
-      ).sort(({ name: a }, { name: b }) => a < b ? -1 : a > b ? 1 : 0)
+      ).sort(({ name: a }, { name: b }) =>
+        // Sort the directories.
+        a < b ? 1 : a > b ? -1 : 0
+      )
     ) {
       // Iterate over each entry directory and process its contents.
       const entry = document.createElement("entry");
This page took 0.054413 seconds and 4 git commands to generate.