allow path to be empty, placing generated site at the root

29237ed0d328c1e2001db91cb2c48a2566e19c7c

tucker <tucker@pangolin.lan> | Sun Sep 28 2025

allow path to be empty, placing generated site at the root
main.ts:23
Before
22
23
24
25
26
27
28
29
  }

  const reposData = await repos(reposConfiguration)
  // TODO: make a better way of making this default to "/repos" so that it doesn't have to
  // be done again in src/repos.ts.
  const reposPath = reposConfiguration.path || "/repos"

  eleventyConfig.addGlobalData("repos", reposData)
  eleventyConfig.addGlobalData("reposConfig", reposConfiguration)
After
22
23
24
25
26
27
28
29
  }

  const reposData = await repos(reposConfiguration)
  // TODO: make a better way of making this default to "" so that it doesn't have to
  // be done again in src/repos.ts.
  const reposPath = reposConfiguration.path || ""

  eleventyConfig.addGlobalData("repos", reposData)
  eleventyConfig.addGlobalData("reposConfig", reposConfiguration)
src/repos.ts:61
Before
60
61
62
63
64
65
    const repoType = reposConfig.repos[repoName]._type
    reposObject[repoName] = {
      branches: repoTuple[1],
      cloneUrl: repoHelpers[repoType].cloneUrl(reposConfig.baseUrl + (reposConfig.path || "/repos"), repoName)
    }
  }
After
60
61
62
63
64
65
    const repoType = reposConfig.repos[repoName]._type
    reposObject[repoName] = {
      branches: repoTuple[1],
      cloneUrl: repoHelpers[repoType].cloneUrl(reposConfig.baseUrl + (reposConfig.path || ""), repoName)
    }
  }