From c8e139fa145d42b97a4876de8f9208d98f0da246 Mon Sep 17 00:00:00 2001 From: alterNERDtive Date: Mon, 30 May 2022 21:16:53 +0200 Subject: [PATCH] github actions have joined the repo --- .github/workflows/create-release.yaml | 44 +++++++++++++++++++++++++++ Directory.build.props | 7 +++-- EDNA.sln | 5 +-- 3 files changed, 51 insertions(+), 5 deletions(-) create mode 100644 .github/workflows/create-release.yaml diff --git a/.github/workflows/create-release.yaml b/.github/workflows/create-release.yaml new file mode 100644 index 0000000..a6902fb --- /dev/null +++ b/.github/workflows/create-release.yaml @@ -0,0 +1,44 @@ +name: Create release on tag push + +on: + push: + tags: + - 'release/*' + +jobs: + build: + name: Build EDNA + runs-on: ubuntu-latest + permissions: + contents: write + + steps: + - name: Checkout source code + uses: actions/checkout@v2 + + - name: Setup .Net + uses: actions/setup-dotnet@v1.1 + with: + dotnet-version: '6.0.x' + + - name: Restore dependencies + run: dotnet restore + + - name: Build + run: dotnet build -c release + + - name: Run tests + run: dotnet test + + - name: Create NuGet package + run: dotnet pack -c release + + - name: Push NuGet package + run: dotnet nuget push "Edna/bin/Release/alterNERDtive.EDNA.*.nupkg" -source 'https://api.nuget.org/v3/index.json' -apikey ${{secrets.NUGET_AUTH_TOKEN}} + + - name: Draft release + uses: ncipollo/release-action@v1 + with: + artifacts: "Edna/bin/Release/alterNERDtive.EDNA.*.nupkg" + bodyFile: "CHANGELOG.md" + draft: true diff --git a/Directory.build.props b/Directory.build.props index 7794f69..a3605d8 100644 --- a/Directory.build.props +++ b/Directory.build.props @@ -1,6 +1,7 @@ - + - 8.0 + 10.0 + enable @@ -21,4 +22,4 @@ - \ No newline at end of file + diff --git a/EDNA.sln b/EDNA.sln index 7ec0162..8a97be4 100644 --- a/EDNA.sln +++ b/EDNA.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.31402.337 +# Visual Studio Version 17 +VisualStudioVersion = 17.3.32519.111 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Edna", "Edna\Edna.csproj", "{544D0ACE-C5B9-47A3-88F8-F81B248FF399}" EndProject @@ -17,6 +17,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution ProjectSection(SolutionItems) = preProject .editorconfig = .editorconfig CHANGELOG.md = CHANGELOG.md + .github\workflows\create-release.yaml = .github\workflows\create-release.yaml Directory.build.props = Directory.build.props README.md = README.md stylecop.json = stylecop.json