feat(ci): Implement GH Actions workflow, disable DOTNET telemetry in … #2
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: Build | |
on: | |
push: | |
pull_request: | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: 6.0.x | |
- name: Restore dependencies | |
run: dotnet restore | |
- name: Build just SharpShell | |
working-directory: ./SharpShell | |
run: dotnet publish -c Release /p:PublishProfile=DeployPublish --no-restore | |
- name: Generate dependency | |
run: python generate_embedded.py | |
- name: Build | |
working-directory: ./SharpShell.Loader | |
run: dotnet build -c Debug /p:RunAnalyzers=false --no-restore | |
- name: Package | |
run: | | |
mkdir release\pwsh | |
xcopy README.md release\ | |
xcopy pwsh.bat release\ | |
xcopy run_pwsh.xml release\pwsh\ | |
xcopy SharpShell.Loader\bin\Debug\net6.0\SharpShell.Loader.dll release\pwsh\ | |
7z a -tzip SharpShell.zip .\release\* | |
- name: Upload artifacts (dotnet) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: SharpShell | |
path: .\release\* | |
- name: Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: SharpShell.zip |