-
Notifications
You must be signed in to change notification settings - Fork 2
39 lines (33 loc) · 1.44 KB
/
PackAndPushAfterMerge.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: PackAndPushAfterMerge
on:
push:
branches:
- master
jobs:
build:
name: ReleaseTheTask
runs-on: windows-latest
steps:
- uses: actions/checkout@v1
- name: Get version number
id: vars
shell: pwsh
run: |
$version = ([xml]($tmp = Get-Content -Path 'Frends.Community.AWS/Frends.Community.AWS.csproj')).SelectSingleNode("Project/PropertyGroup/Version").InnerText
echo "::set-output name=version_number::$version"
- name: Pack release version of task
run: dotnet pack --configuration Release --include-source
- name: Push NuGet package to the (prod) feed
run: dotnet nuget push Frends.Community.AWS\bin\Release\Frends.Community.AWS.*.nupkg --api-key ${{ secrets.COMMUNITY_FEED_API_KEY }} --source https://www.myget.org/F/frends-community/api/v2/package
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.vars.outputs.version_number }}
release_name: Release ${{ steps.vars.outputs.version_number }}
body: |
You can install the task via frends UI Task View or you can find the NuGet package from https://www.myget.org/F/frends-community/api/v2/package/Frends.Community.AWS/${{ steps.vars.outputs.version_number }}
draft: false
prerelease: false