Skip to content

Commit

Permalink
test publish 5
Browse files Browse the repository at this point in the history
  • Loading branch information
ZEXSM committed Oct 28, 2023
1 parent 2d82088 commit ba3395c
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: OData.QueryBuilder
name: OData.QueryBuilder CI\CD
on: push
env:
DOTNET_VERSION: '3.1.x'
Expand Down Expand Up @@ -33,7 +33,7 @@ jobs:
cd:
needs: ci
if: github.ref == 'refs/heads/feature/migrate-to-github-actions'
name: release
name: publish
runs-on: ubuntu-latest
environment: cd
steps:
Expand Down Expand Up @@ -62,4 +62,5 @@ jobs:
run: |
dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} --skip-duplicate
git tag v${{ steps.create_tag.outputs.release_package_version }}
git push origin v${{ steps.create_tag.outputs.release_package_version }}
git push origin v${{ steps.create_tag.outputs.release_package_version }}
gh release create -t "v${{ steps.create_tag.outputs.release_package_version }}" --generate-notes
27 changes: 27 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: OData.QueryBuilder Create release
on:
push:
tags:
- 'v*'
name: Create Release
jobs:
build:
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
body: |
Changes in this Release
- First Change
- Second Change
draft: false
prerelease: false
1 change: 1 addition & 0 deletions OData.QueryBuilder.sln
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{D95B88FB-7257-421E-8AA3-BD85C63ECBE6}"
ProjectSection(SolutionItems) = preProject
.github\workflows\ci-cd.yml = .github\workflows\ci-cd.yml
.github\workflows\release.yml = .github\workflows\release.yml
EndProjectSection
EndProject
Global
Expand Down

0 comments on commit ba3395c

Please sign in to comment.