-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Changed pipeline logic * Fix to restore * FIX restore ? * Revert "FIX restore ?" This reverts commit fe32722. * whoops
- Loading branch information
Showing
2 changed files
with
33 additions
and
12 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
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 |
---|---|---|
|
@@ -24,7 +24,7 @@ jobs: | |
|
||
# BUILD APP | ||
build: | ||
|
||
if: ( github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.head_branch == 'main' ) || startsWith(github.ref, 'refs/tags/v') | ||
strategy: | ||
matrix: | ||
# runtime: [x64, x86] | ||
|
@@ -43,19 +43,17 @@ jobs: | |
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
# Install the .NET Core workload | ||
- name: Install .NET Core | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: ${{vars.DOTNET_VERSION}} | ||
|
||
# Execute all unit tests in the solution | ||
- name: Execute unit tests | ||
run: dotnet test | ||
|
||
# Restore the application to populate the obj folder with RuntimeIdentifiers | ||
- name: Restore the application | ||
run: dotnet restore | ||
|
@@ -68,7 +66,7 @@ jobs: | |
|
||
# Pub | ||
- name: Publish the application ${{ matrix.runtime }} | ||
run: dotnet publish --configuration $env:Configuration -a $env:Runtime --self-contained true /p:useapphost=true --output .\$env:ZIP_NAME$env:Runtime ./FASTER/FASTER.csproj | ||
run: dotnet publish --configuration $env:Configuration -a $env:Runtime --self-contained true -p:PublishSingleFile=true /p:useapphost=true --output .\$env:ZIP_NAME$env:Runtime ./FASTER/FASTER.csproj | ||
env: | ||
Runtime: ${{ matrix.runtime }} | ||
|
||
|
@@ -79,6 +77,28 @@ jobs: | |
env: | ||
Runtime: ${{ matrix.runtime }} | ||
|
||
- name: Upload artifact | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: build-${{ matrix.runtime }} | ||
path: .\${{ env.ZIP_NAME}}${{ matrix.runtime }}.zip | ||
|
||
release: | ||
needs: build | ||
runs-on: windows-latest | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 # required for tags history processing | ||
|
||
- name: Download x64 artifact | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: build-x64 | ||
path: ./artifacts | ||
|
||
# Get version number | ||
- name: get-net-sdk-project-versions-action | ||
uses: kzrnm/[email protected] | ||
|
@@ -186,11 +206,10 @@ jobs: | |
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
Runtime: ${{ matrix.runtime }} | ||
with: | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps | ||
asset_path: .\${{ env.ZIP_NAME}}${{ env.Runtime }}.zip | ||
asset_name: ${{ env.ZIP_NAME}}${{ env.Runtime }}.zip | ||
asset_path: ./artifacts/${{ env.ZIP_NAME}}x64.zip | ||
asset_name: ${{ env.ZIP_NAME}}x64.zip | ||
asset_content_type: application/zip | ||
|
||
# Create Nightly Release | ||
|
@@ -199,7 +218,6 @@ jobs: | |
uses: andelf/nightly-release@main | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
Runtime: ${{ matrix.runtime }} | ||
with: | ||
tag_name: nightly | ||
name: 'Nightly Release v${{ env.VERSION }}' | ||
|
@@ -209,4 +227,4 @@ jobs: | |
${{ steps.get-changes.outputs.changes }} | ||
--- | ||
prerelease: true | ||
files: .\${{ env.ZIP_NAME}}${{ env.Runtime }}.zip | ||
files: ./artifacts/${{ env.ZIP_NAME}}x64.zip |