docs: the README changelog starts at v1.5.0, and packaging stops on a README Thunderstore would refuse
This commit is contained in:
parent
aa252c86ca
commit
4c7e0ec16d
2 changed files with 8 additions and 32 deletions
|
|
@ -47,6 +47,13 @@ $version = (Get-Content $Manifest -Raw | ConvertFrom-Json).version_number
|
|||
# them, because they work on the wiki and on the git host.
|
||||
$readmeText = [System.IO.File]::ReadAllText((Resolve-Path $Readme).Path)
|
||||
$readmeText = [regex]::Replace($readmeText, '\[([^\]]+)\]\(#[^)]*\)', '$1')
|
||||
|
||||
# Thunderstore refuses a README over 100000 characters (hit at v1.6.7). Stop here rather than
|
||||
# ship a zip the upload rejects: cut the oldest changelog versions in README.md and move the
|
||||
# "Versions before vX are no longer listed here" line up with them. The wiki keeps them all.
|
||||
if ($readmeText.Length -gt 100000) {
|
||||
throw "README.md is $($readmeText.Length) characters; Thunderstore allows 100000. Cut the oldest changelog versions in README.md."
|
||||
}
|
||||
$packagedReadme = Join-Path ([System.IO.Path]::GetTempPath()) ("RacesOfValheim_README_" + [guid]::NewGuid().ToString('N') + ".md")
|
||||
[System.IO.File]::WriteAllText($packagedReadme, $readmeText, (New-Object System.Text.UTF8Encoding($false)))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue