Skip to content

Commit cae85f5

Browse files
committed
tags added.
1 parent 742083f commit cae85f5

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

‎.github/workflows/nuget.yml‎

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: "Deploy to Nuget"
22

3-
on: ["push"]
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
47

58
env:
69
PROJECT_PATH: 'FmgLib.Localization.csproj'
@@ -26,8 +29,12 @@ jobs:
2629
- name: 'Build project'
2730
run: dotnet build ${{ env.PROJECT_PATH }} --no-restore --configuration Release
2831

32+
- name: 'Get version'
33+
id: version
34+
uses: battila7/get-version-action@v2
35+
2936
- name: 'Pack project'
30-
run: dotnet pack ${{ env.PROJECT_PATH }} --no-restore --no-build --configuration Release --include-symbols --output ${{ env.PACKAGE_OUTPUT_DIRECTORY }}
37+
run: dotnet pack ${{ env.PROJECT_PATH }} --no-restore --no-build --configuration Release --include-symbols -p:PackageVersion=${{ steps.version.output.version-without-v }} --output ${{ env.PACKAGE_OUTPUT_DIRECTORY }}
3138

3239
- name: 'Push package'
3340
run: dotnet nuget push ${{ env.PACKAGE_OUTPUT_DIRECTORY }}\*.nupkg -k ${{ secrets.NUGET_AUTH_TOKEN }} -s ${{ env.NUGET_SOURCE_URL }}

0 commit comments

Comments
 (0)