This repository has been archived by the owner on Sep 20, 2024. It is now read-only.
generated from LiteLDev/liteloaderbds-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* build: add workflow * feat: support install bdslib and cache * fix: try * fix: try * fix: try * fix: try * fix: try * fix: try * fix: try * build: only master and dev * build: only master and dev
- Loading branch information
CoolLoong
authored
Dec 14, 2023
1 parent
c95a138
commit 5694fa5
Showing
3 changed files
with
127 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
on: | ||
push: | ||
branches: | ||
- master | ||
- dev | ||
paths: | ||
- .github/workflows/build.yml | ||
- scripts/localbdslibrary.lua | ||
- src/** | ||
- xmake.lua | ||
pull_request: | ||
branches: | ||
- master | ||
- dev | ||
paths: | ||
- .github/workflows/build.yml | ||
- scripts/localbdslibrary.lua | ||
- src/** | ||
- xmake.lua | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Read bdsversion file | ||
id: read-bdsversion | ||
run: | | ||
$content = Get-Content -Path .\bdsversion -Raw | ||
$type = ($content | Select-String -Pattern 'type=(.*)' | ForEach-Object { $_.Matches.Groups[1].Value }).Trim() | ||
$version = ($content | Select-String -Pattern 'version=(.*)' | ForEach-Object { $_.Matches.Groups[1].Value }).Trim() | ||
echo "::set-output name=version_type::$type" | ||
echo "::set-output name=version_number::$version" | ||
printf '%s\n' "$type" | ||
printf '%s\n' "$version" | ||
- uses: xmake-io/github-action-setup-xmake@v1 | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/AppData/Local/.xmake | ||
.xmake | ||
build/bds/lib | ||
key: | | ||
xmake-dataextractor-windows-x64-${{ github.sha }} | ||
xmake-dataextractor-windows-x64-${{ github.sha }} | ||
bdslib-${{ steps.read-bdsversion.outputs.version_type }}-${{ steps.read-bdsversion.outputs.version_number }} | ||
restore-keys: | | ||
xmake-dataextractor-windows-x64- | ||
xmake-dataextractor-windows-x64- | ||
- run: | | ||
xmake repo -u | ||
- run: | | ||
xmake bds-lib -b --${{ steps.read-bdsversion.outputs.version_type }}=${{ steps.read-bdsversion.outputs.version_number }} | ||
- run: | | ||
xmake f -a x64 -m release -p windows -v -y --ccache=n | ||
- run: | | ||
xmake -w -y | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
name: DataExtractor-Windows-X64-${{ github.sha }} | ||
path: | | ||
build/windows/x64/release/DataExtractor.dll | ||
build/windows/x64/release/DataExtractor.pdb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
type=release | ||
version=1.20.50.03 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters