forked from antonpup/Aurora
-
-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from Aytackydln/github-actions
GitHub actions
- Loading branch information
Showing
8 changed files
with
622 additions
and
449 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,106 @@ | ||
name: Aurora CD | ||
|
||
on: | ||
push: | ||
branches: [ dev ] | ||
|
||
jobs: | ||
|
||
build: | ||
|
||
strategy: | ||
matrix: | ||
configuration: [Release] | ||
|
||
runs-on: windows-latest # For a list of available runner types, refer to | ||
# https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on | ||
|
||
env: | ||
Solution_Name: Project-Aurora/Project-Aurora.sln | ||
|
||
steps: | ||
- name: Generate build number | ||
id: buildnumber | ||
uses: einaregilsson/build-number@v3 | ||
with: | ||
token: ${{secrets.github_token}} | ||
|
||
- uses: rishabhgupta/split-by@v1 | ||
id: split | ||
with: | ||
string: ${{github.repository}} | ||
split-by: '/' | ||
- run: | | ||
echo "${{github.repository}}" | ||
- run: | | ||
echo "${{ steps.split.outputs._0}}" | ||
- run: | | ||
echo "${{ steps.split.outputs._1}}" | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
submodules: true | ||
|
||
# Install the .NET Core workload | ||
- name: Install .NET Core | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: 5.0.x | ||
|
||
# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild | ||
- name: Setup MSBuild.exe | ||
uses: microsoft/[email protected] | ||
|
||
# Restore the application to populate the obj folder with RuntimeIdentifiers | ||
- name: Restore the application | ||
run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration | ||
env: | ||
Configuration: ${{ matrix.configuration }} | ||
|
||
# Restore the application to populate the obj folder with RuntimeIdentifiers | ||
- name: Build | ||
run: msbuild $env:Solution_Name /p:Configuration=$env:Configuration | ||
env: | ||
APPVEYOR_BUILD_VERSION: v${{steps.buildnumber.outputs.build_number}} | ||
OWNER: ${{ steps.split.outputs._0 }} | ||
REPOSITORY: ${{ steps.split.outputs._1 }} | ||
Configuration: ${{ matrix.configuration }} | ||
|
||
# Decode the base 64 encoded pfx and save the Signing_Certificate | ||
#- name: Decode the pfx | ||
# run: | | ||
# $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}") | ||
# $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx | ||
# [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte) | ||
|
||
# Create the app package by building and packaging the Windows Application Packaging project | ||
- name: Building the installer | ||
run: | | ||
"%programfiles(x86)%\Inno Setup 6\iscc.exe" /DEXTERNAL_VERSION=${{steps.buildnumber.outputs.build_number}} Installer\installer.iss | ||
shell: cmd | ||
|
||
- name: Archive Release | ||
uses: vimtor/action-zip@v1 | ||
with: | ||
files: Build\Release\ | ||
dest: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip | ||
|
||
- name: Installer Release | ||
uses: svenstaro/[email protected] | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
file: "Aurora-setup-v${{steps.buildnumber.outputs.build_number}}.exe" | ||
tag: v${{steps.buildnumber.outputs.build_number}} | ||
overwrite: false | ||
prerelease: true | ||
|
||
- name: Zip Release | ||
uses: svenstaro/[email protected] | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
file: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip | ||
tag: v${{steps.buildnumber.outputs.build_number}} | ||
overwrite: false | ||
prerelease: true |
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,104 @@ | ||
name: Aurora CD | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
|
||
jobs: | ||
|
||
build: | ||
|
||
strategy: | ||
matrix: | ||
configuration: [Release] | ||
|
||
runs-on: windows-latest # For a list of available runner types, refer to | ||
# https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on | ||
|
||
env: | ||
Solution_Name: Project-Aurora/Project-Aurora.sln | ||
|
||
steps: | ||
- name: Generate build number | ||
id: buildnumber | ||
uses: einaregilsson/build-number@v3 | ||
with: | ||
token: ${{secrets.github_token}} | ||
|
||
- uses: rishabhgupta/split-by@v1 | ||
id: split | ||
with: | ||
string: ${{github.repository}} | ||
split-by: '/' | ||
- run: | | ||
echo "${{github.repository}}" | ||
- run: | | ||
echo "${{ steps.split.outputs._0}}" | ||
- run: | | ||
echo "${{ steps.split.outputs._1}}" | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
submodules: true | ||
|
||
# Install the .NET Core workload | ||
- name: Install .NET Core | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: 5.0.x | ||
|
||
# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild | ||
- name: Setup MSBuild.exe | ||
uses: microsoft/[email protected] | ||
|
||
# Restore the application to populate the obj folder with RuntimeIdentifiers | ||
- name: Restore the application | ||
run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration | ||
env: | ||
Configuration: ${{ matrix.configuration }} | ||
|
||
# Restore the application to populate the obj folder with RuntimeIdentifiers | ||
- name: Build | ||
run: msbuild $env:Solution_Name /p:Configuration=$env:Configuration | ||
env: | ||
APPVEYOR_BUILD_VERSION: v${{steps.buildnumber.outputs.build_number}} | ||
OWNER: ${{ steps.split.outputs._0 }} | ||
REPOSITORY: ${{ steps.split.outputs._1 }} | ||
Configuration: ${{ matrix.configuration }} | ||
|
||
# Decode the base 64 encoded pfx and save the Signing_Certificate | ||
#- name: Decode the pfx | ||
# run: | | ||
# $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}") | ||
# $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx | ||
# [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte) | ||
|
||
# Create the app package by building and packaging the Windows Application Packaging project | ||
- name: Building the installer | ||
run: | | ||
"%programfiles(x86)%\Inno Setup 6\iscc.exe" /DEXTERNAL_VERSION=${{steps.buildnumber.outputs.build_number}} Installer\installer.iss | ||
shell: cmd | ||
|
||
- name: Archive Release | ||
uses: vimtor/action-zip@v1 | ||
with: | ||
files: Build\Release\ | ||
dest: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip | ||
|
||
- name: Installer Release | ||
uses: svenstaro/[email protected] | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
file: "Aurora-setup-v${{steps.buildnumber.outputs.build_number}}.exe" | ||
tag: v${{steps.buildnumber.outputs.build_number}} | ||
overwrite: false | ||
|
||
- name: Zip Release | ||
uses: svenstaro/[email protected] | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
file: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip | ||
tag: v${{steps.buildnumber.outputs.build_number}} | ||
overwrite: false |
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
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
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
Oops, something went wrong.