-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from Crown0815/ci/Introduce-proper-github-releases
Ci/introduce proper GitHub releases
- Loading branch information
Showing
2 changed files
with
27 additions
and
15 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,33 +10,44 @@ jobs: | |
runs-on: ubuntu-latest | ||
|
||
steps: | ||
|
||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup .NET Core | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
global-json-file: global.json | ||
|
||
- name: Install GitVersion | ||
uses: gittools/actions/gitversion/setup@v0.9.7 | ||
uses: gittools/actions/gitversion/setup@v0.10.2 | ||
with: | ||
versionSpec: '5.x' | ||
|
||
- name: Determine Version | ||
id: version | ||
uses: gittools/actions/gitversion/execute@v0.9.7 | ||
uses: gittools/actions/gitversion/execute@v0.10.2 | ||
with: | ||
useConfigFile: true | ||
|
||
- name: Setup .NET Core | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
global-json-file: global.json | ||
|
||
- name: Package | ||
run: dotnet pack --configuration Release --output nuget --nologo -p:Version=${{ steps.version.outputs.nuGetVersionV2 }} | ||
|
||
- name: Tag Repository | ||
uses: rickstaa/action-create-tag@v1 | ||
- name: Generate Release Notes | ||
run: |- | ||
dotnet tool install --global ConventionalChangelog --version 0.7.0 | ||
changelog "${{ github.workspace }}" >> "changelog.md" | ||
- name: Create a Release | ||
uses: comnoco/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag: "v${{ steps.version.outputs.semVer }}" | ||
tag_name: "v${{ steps.version.outputs.semVer }}" | ||
release_name: "${{ steps.version.outputs.semVer }}" | ||
body_path: "changelog.md" | ||
prerelease: ${{ steps.version.outputs.preReleaseLabel != '' }} | ||
|
||
- name: Publish | ||
run: dotnet nuget push "**/*.nupkg" --source nuget.org --api-key ${{ secrets.NUGET_API_KEY }} | ||
# - name: Publish | ||
# run: dotnet nuget push "**/*.nupkg" --source nuget.org --api-key ${{ secrets.NUGET_API_KEY }} |