feat(functions): V4 (#1) #6
Workflow file for this run
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
on: | |
push: | |
tags: | |
- v* | |
env: | |
DOTNET_VERSION: '6.0' | |
name: release | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout main | |
uses: actions/checkout@main | |
- name: setup dotnet ${{ env.DOTNET_VERSION }} | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: ${{ env.DOTNET_VERSION }} | |
source-url: https://nuget.pkg.github.com/azure-devops-compliance/index.json | |
env: | |
NUGET_AUTH_TOKEN: ${{ secrets.PAT }} | |
- name: dotnet publish | |
run: dotnet publish -o ./out Functions/Functions.csproj -c release | |
- name: zip | |
run: | | |
pushd ./out | |
zip -r ../release.zip . | |
popd | |
- name: create release | |
id: release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.PAT }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: Release ${{ github.ref }} | |
body: "" | |
draft: false | |
prerelease: false | |
- name: upload assets | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.PAT }} | |
with: | |
upload_url: ${{ steps.release.outputs.upload_url }} | |
asset_path: release.zip | |
asset_name: release.zip | |
asset_content_type: application/zip |