Update Kanvas version; #47
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
name: Kuriimu2 EtoForms Dev | |
on: | |
push: | |
branches: | |
- imgui | |
jobs: | |
build: | |
#timeout-minutes: 10 | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: nuget/setup-nuget@v1 | |
- name: Wait for other dev builds | |
uses: softprops/turnstyle@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Setup .NET Core | |
uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: 3.1.302 | |
- name: Setup NuGet sources | |
run: | | |
nuget sources add -name LocalFeed -source D:\a\Kuriimu2\Kuriimu2\nuget -verbosity detailed | |
- name: Get manifest version | |
id: set_version | |
uses: notiz-dev/github-action-json-property@release | |
with: | |
path: './src/Kuriimu2.ImGui/Resources/version.json' | |
prop_path: 'version' | |
- name: Create manifests | |
run: | | |
mkdir ./update/Windows | |
mkdir ./update/Linux | |
mkdir ./update/Mac | |
echo '{"source_type": "Github Action", "version": "${{ steps.set_version.outputs.prop }}", "build_number": "${{ github.run_id }}", "application_name": "Kuriimu2.exe" }' > ./update/Windows/manifest.json | |
echo '{"source_type": "Github Action", "version": "${{ steps.set_version.outputs.prop }}", "build_number": "${{ github.run_id }}", "application_name": "Kuriimu2" }' > ./update/Linux/manifest.json | |
echo '{"source_type": "Github Action", "version": "${{ steps.set_version.outputs.prop }}", "build_number": "${{ github.run_id }}", "application_name": "Kuriimu2" }' > ./update/Mac/manifest.json | |
echo '{"source_type": "Github Action", "version": "${{ steps.set_version.outputs.prop }}", "build_number": ${{ github.run_id }} }' > ./src/Kuriimu2.ImGui/Resources/version.json | |
- name: Pack libraries | |
run: | | |
dotnet build ./src/Kontract/Kontract.csproj --configuration Release | |
dotnet build ./src/Komponent/Komponent.csproj --configuration Release | |
dotnet build ./src/Kanvas/Kanvas.csproj --configuration Release | |
dotnet build ./src/Kompression/Kompression.csproj --configuration Release | |
dotnet build ./src/Kryptography/Kryptography.csproj --configuration Release | |
dotnet pack ./src/Kontract/Kontract.csproj --configuration Release --verbosity normal | |
dotnet pack ./src/Komponent/Komponent.csproj --configuration Release --verbosity normal | |
dotnet pack ./src/Kanvas/Kanvas.csproj --configuration Release --verbosity normal | |
dotnet pack ./src/Kompression/Kompression.csproj --configuration Release --verbosity normal | |
dotnet pack ./src/Kryptography/Kryptography.csproj --configuration Release --verbosity normal | |
- name: Publish plugins | |
run: | | |
dotnet build ./plugins/ArcSystemWorks/ArcSystemWorks.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Atlus/Atlus.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/BandaiNamco/BandaiNamco.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Capcom/Capcom.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Circus/Circus.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Criware/Criware.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/DotEmu/DotEmu.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/DreamCatcher/DreamCatcher.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Felistella/Felistella.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/FurYu/FurYu.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/HeadstrongGames/HeadstrongGames.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/HuneX/HuneX.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/IntiCreates/IntiCreates.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Kadokawa/Kadokawa.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/KhronosGroup/KhronosGroup.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/KoeiTecmo/KoeiTecmo.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Konami/Konami.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Level5/Level5.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/MercurySteam/MercurySteam.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/MostWantedEntertainment/MostWantedEntertainment.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Nintendo/Nintendo.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/NipponIchiSoftware/NipponIchiSoftware.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Primula/Primula.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Sega/Sega.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Shade/Shade.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/Sony/Sony.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/SpikeChunsoft/SpikeChunsoft.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/SquareEnix/SquareEnix.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/StingEntertainment/StingEntertainment.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/SuperflatGames/SuperflatGames.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/TamSoft/TamSoft.sln --output ./dist/final/plugins --configuration Release | |
dotnet build ./plugins/VBlankEntertainment/VBlankEntertainment.sln --output ./dist/final/plugins --configuration Release | |
rm ./dist/final/plugins/*.pdb | |
rm ./dist/final/plugins/*.deps.json | |
- name: Publish Imgui application with dotnet | |
run: | | |
dotnet publish ./src/Kuriimu2.ImGui/Kuriimu2.ImGui.csproj --output ./dist/final/Windows --configuration Release --framework netcoreapp31 --runtime win-x64 /p:PublishSingleFile=true | |
dotnet publish ./src/Kuriimu2.ImGui/Kuriimu2.ImGui.csproj --output ./dist/final/Linux --configuration Release --framework netcoreapp31 --runtime linux-x64 /p:PublishSingleFile=true | |
dotnet publish ./src/Kuriimu2.ImGui/Kuriimu2.ImGui.csproj --output ./dist/final/Mac --configuration Release --framework netcoreapp31 --runtime osx-x64 /p:PublishSingleFile=true | |
mv ./dist/final/Windows/Kuriimu2.ImGui.exe ./dist/final/Windows/Kuriimu2.exe | |
mv ./dist/final/Linux/Kuriimu2.ImGui ./dist/final/Linux/Kuriimu2 | |
mv ./dist/final/Mac/Kuriimu2.ImGui ./dist/final/Mac/Kuriimu2 | |
rm ./dist/final/Windows/*.pdb | |
rm ./dist/final/Linux/*.pdb | |
rm ./dist/final/Mac/*.pdb | |
- name: Copy plugins to applications | |
run: | | |
xcopy /I .\dist\final\plugins .\dist\final\Windows\plugins | |
xcopy /I .\dist\final\plugins .\dist\final\Linux\plugins | |
xcopy /I .\dist\final\plugins .\dist\final\Mac\plugins | |
shell: cmd | |
- name: Zip Windows release | |
uses: papeloto/action-zip@v1 | |
with: | |
files: ./dist/final/Windows | |
dest: ./update/Windows/latest.zip | |
- name: Zip Linux release | |
uses: papeloto/action-zip@v1 | |
with: | |
files: ./dist/final/Linux | |
dest: ./update/Linux/latest.zip | |
- name: Zip Mac release | |
uses: papeloto/action-zip@v1 | |
with: | |
files: ./dist/final/Mac | |
dest: ./update/Mac/latest.zip | |
- name: Install openSSL | |
uses: crazy-max/ghaction-chocolatey@v1 | |
with: | |
args: install openssl.light | |
- name: Sign release | |
run: | | |
echo "$PRIVATE_KEY" > privatekey.pem | |
openssl dgst -sha512 -sign privatekey.pem -out ./update/Windows/latest.sig ./update/Windows/latest.zip | |
openssl dgst -sha512 -sign privatekey.pem -out ./update/Linux/latest.sig ./update/Linux/latest.zip | |
openssl dgst -sha512 -sign privatekey.pem -out ./update/Mac/latest.sig ./update/Mac/latest.zip | |
shell: bash | |
env: | |
PRIVATE_KEY: ${{secrets.PRIVATE_KEY_IMGUI}} | |
- name: Clone update repository | |
run: git clone https://github.com/FanTranslatorsInternational/Kuriimu2-ImGuiForms-Update ./update_repo | |
- name: Move update files to update repo | |
run: | | |
mv -Force ./update/Windows/* ./update_repo/Windows | |
mv -Force ./update/Linux/* ./update_repo/Linux | |
mv -Force ./update/Mac/* ./update_repo/Mac | |
- name: Commit changes to update repo | |
run: | | |
cd ./update_repo | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Action" | |
git add * | |
git commit -m "Update binaries" -a | |
- name: Push changes to update repo | |
uses: ad-m/github-push-action@master | |
with: | |
directory: ./update_repo | |
repository: FanTranslatorsInternational/Kuriimu2-ImGuiForms-Update | |
github_token: ${{ secrets.PRIVATE_ACCESS_TOKEN }} | |
- name: Upload Windows artifact | |
uses: actions/upload-artifact@v1 | |
with: | |
name: Kuriimu2 Windows | |
path: ./dist/final/Windows | |
- name: Upload Linux artifact | |
uses: actions/upload-artifact@v1 | |
with: | |
name: Kuriimu2 Linux | |
path: ./dist/final/Linux | |
- name: Upload Mac artifact | |
uses: actions/upload-artifact@v1 | |
with: | |
name: Kuriimu2 Mac | |
path: ./dist/final/Mac |