Update PowerShell version in workflow #4
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: Sign scans.exe with cosign and create a release | |
on: | |
push: | |
branches: | |
- refactor | |
jobs: | |
release: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up PowerShell | |
uses: PowerShell/powershell@7 # Update the repository name | |
- name: Run compile.ps1 | |
run: pwsh -File compile.ps1 -Version "1.3.0.${{ github.run_number }}" | |
- name: Install cosign | |
uses: sigstore/[email protected] | |
- name: Generate key pair | |
run: cosign generate-key-pair | |
- name: Sign scans.exe | |
run: cosign sign -key cosign.key scans.exe | |
- name: Create Release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: "1.3.0.${{ github.run_number }}" | |
release_name: "Release 1.3.0.${{ github.run_number }}" | |
draft: false | |
prerelease: false | |
- name: Upload Release Asset | |
id: upload_release_asset | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./scans.exe | |
asset_name: scans.exe | |
asset_content_type: application/octet-stream |