Skip to content

Commit 397343b

Browse files
committed
Release 2.1.2 [release 2.1.2]
1 parent 8789204 commit 397343b

File tree

4 files changed

+36
-6
lines changed

4 files changed

+36
-6
lines changed

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ jobs:
6161
$AX_ROOT = $(pwd).Path
6262
./1k/fetch.ps1 -name 'oboe' -prefix $(Join-Path $AX_ROOT 'cache') -cfg $(Join-Path $AX_ROOT 'manifest.json')
6363
./build.ps1 -xc '-DAX_WITH_LZ4=ON,-DAX_WITH_CARES=ON,-DAX_WITH_YAML_CPP=ON,-DAX_WITH_KCP=ON' -c
64-
./tools/ci/make-pkg.ps1 -version "${{ steps.forward_ver.outputs.release_ver }}"
64+
./tools/ci/publish.ps1 -version "${{ steps.forward_ver.outputs.release_ver }}"
6565
6666
- name: Publish to github release page
6767
if: ${{ steps.make_pkg.outputs.release_tag != '' }}

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## axmol-2.1.2 ?? 2024
1+
## axmol-2.1.2 Feb.25 2024
22

33
### BugFixes
44

thirdparty/glfw/src/win32_window.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1282,7 +1282,7 @@ static int createNativeWindow(_GLFWwindow* window,
12821282
const _GLFWfbconfig* fbconfig)
12831283
{
12841284
int frameX, frameY, frameWidth, frameHeight;
1285-
WCHAR* wideTitle;
1285+
WCHAR* wideTitle;
12861286
DWORD style = getWindowStyle(window);
12871287
DWORD exStyle = getWindowExStyle(window);
12881288

tools/ci/make-pkg.ps1 renamed to tools/ci/publish.ps1

Lines changed: 33 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ if (!$version -or ($version -eq 'auto')) {
2424
$axver += "-$commitHash"
2525
$axver += '-nightly'
2626
}
27-
} else {
27+
}
28+
else {
2829
$axver += $(parse_axver 'PATCH')
2930
}
3031
return $axver
@@ -306,6 +307,36 @@ public class UnixFileStream : FileStream
306307
return $Script:total
307308
}
308309

310+
# Generate release note
311+
312+
if ($prerelease -eq 'false') {
313+
$release_note = Join-Path $AX_ROOT "release_note_${version}.txt"
314+
}
315+
else {
316+
$release_note = Join-Path $AX_ROOT "release_note_draft.txt"
317+
}
318+
319+
New-Item -Path $release_note -ItemType File -Force
320+
321+
$changelog_lines = Get-Content (Join-Path $AX_ROOT 'CHANGELOG.md')
322+
$release_count = 0
323+
$release_note_content = ''
324+
foreach ($line in $changelog_lines) {
325+
if ($line.StartsWith('## axmol-')) {
326+
++$release_count
327+
if ($release_count -lt 2) {
328+
$release_note_content += "*The $version release is a minor ``LTS`` release for bugfixes and improvements*`n"
329+
} else {
330+
break
331+
}
332+
}
333+
else {
334+
$release_note_content += "$line`n"
335+
}
336+
}
337+
338+
[System.IO.File]::AppendAllText($release_note, $release_note_content)
339+
309340
# Compress-Archive @compress_args
310341
$total = Compress-ArchiveEx @compress_args -Force
311342

@@ -316,8 +347,7 @@ Write-Host "Create package $pkg_file_path done, ${total} files found, MD5: $md5_
316347
Pop-Location
317348

318349
if ($env:GITHUB_ACTIONS -eq 'true') {
319-
$release_note = Join-Path $AX_ROOT "release_note_draft.txt"
320-
[System.IO.File]::WriteAllText($release_note, "## MD5 Hash of the release artifacts`n - ``${pkg_file_name}``: $md5_digest")
350+
[System.IO.File]::AppendAllText($release_note, "## MD5 Hash of the release artifacts`n - ``${pkg_file_name}``: $md5_digest")
321351
echo "release_tag=v$version" >> ${env:GITHUB_OUTPUT}
322352
echo "release_pkg=$pkg_file_name" >> ${env:GITHUB_OUTPUT}
323353
echo "release_note=$release_note" >> ${env:GITHUB_OUTPUT}

0 commit comments

Comments
 (0)