Switch to Forgejo link
This commit is contained in:
parent
a07665962a
commit
6744165d3e
1 changed files with 3 additions and 3 deletions
|
@ -167,13 +167,13 @@ module.exports = {
|
|||
}
|
||||
|
||||
async function updateCommits() {
|
||||
var siteResponse = await (await fetch(`https://github.com/Violets-puragtory/Violets-Purgatory.dev/tree/${process.env.BRANCH || "origin"}`)).text()
|
||||
var siteResponse = await (await fetch(`https://git.violets-purgatory.dev/bingus_violet/violets-purgatory/src/branch/${process.env.BRANCH || "origin"}`)).text()
|
||||
var commits = siteResponse.substring(0, siteResponse.indexOf("Commits"))
|
||||
|
||||
// commits = commits.substring(commits.lastIndexOf("<b>") + 3, commits.lastIndexOf("</b>"))
|
||||
commits = commits.substring(commits.lastIndexOf("<b>") + 3, commits.lastIndexOf("</b>"))
|
||||
// ^ this works for Forgejo (codeberg)
|
||||
|
||||
commits = commits.substring(commits.lastIndexOf(">") + 1)
|
||||
// commits = commits.substring(commits.lastIndexOf(">") + 1)
|
||||
// ^ This works for Github (fuck you Github)
|
||||
|
||||
commitCount = commits.toString()
|
||||
|
|
Loading…
Reference in a new issue