X-Git-Url: https://git.ladys.computer/GitWikiWeb/blobdiff_plain/c539e7ea81a37c86e7fb13f0ba98ea90b7aefe9e..9cfc66dd6cde8171644c8a58f98983ca5a2b7676:/build.js diff --git a/build.js b/build.js index bd8ff27..ca07283 100644 --- a/build.js +++ b/build.js @@ -664,7 +664,8 @@ class GitWikiWebPage { } const results = new Array(6); const seen = new Set(); - let recency = 5; + const maxRecency = Math.max(config.max_recency | 0, 0); + let recency = maxRecency; let current; do { const show = new Deno.Command("git", { @@ -672,7 +673,7 @@ class GitWikiWebPage { "show", "-s", "--format=%H%x00%cI%x00%cD", - recency ? `HEAD~${5 - recency}` : commit, + recency ? `HEAD~${maxRecency - recency}` : commit, ], stdout: "piped", stderr: "piped",