Skip to content

Commit 5f039d4

Browse files
authored
Merge pull request #3 from soernt/develop
Develop
2 parents 90d257a + a8201b1 commit 5f039d4

File tree

5 files changed

+97
-63
lines changed

5 files changed

+97
-63
lines changed

.github/workflows/build_and_test.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
name: Build, test and deploy
2+
3+
on:
4+
push:
5+
pull_request:
6+
7+
env:
8+
# Stop wasting time caching packages
9+
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
10+
# Disable sending usage data to Microsoft
11+
DOTNET_CLI_TELEMETRY_OPTOUT: true
12+
13+
# Official NuGet Feed settings
14+
NUGET_FEED: https://api.nuget.org/v3/index.json
15+
16+
jobs:
17+
build_test_deploy:
18+
runs-on: ubuntu-20.04
19+
defaults:
20+
run:
21+
working-directory: ./source
22+
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@v2
26+
with:
27+
fetch-depth: 0
28+
29+
- name: Setup GitVersion
30+
uses: gittools/actions/gitversion/[email protected]
31+
with:
32+
versionSpec: '5.8.1'
33+
34+
- name: Determine Version
35+
id: gitversion
36+
uses: gittools/actions/gitversion/[email protected]
37+
38+
- name: Setup .NET
39+
uses: actions/setup-dotnet@v1
40+
with:
41+
dotnet-version: 6.0.x
42+
43+
- name: Restore dependencies
44+
run: dotnet restore
45+
46+
- name: Build Release version
47+
run: dotnet build --no-restore --configuration Release /p:AssemblyVersion=${{ steps.gitversion.outputs.assemblySemFileVer }} /p:FileVersion=${{ steps.gitversion.outputs.assemblySemFileVer }} /p:InformationalVersion=${{ steps.gitversion.outputs.Sha }}
48+
49+
# - name: Run Tests
50+
# run: dotnet test --configuration Release --no-restore --verbosity normal --collect:"XPlat Code Coverage" --settings Marten.AspNetCore.Identity.Tests/coverlet.runsettings
51+
52+
- name: Pack
53+
run: dotnet pack --no-build --output ./output --configuration Release /p:PackageVersion=${{ steps.gitversion.outputs.nuGetVersionV2 }}
54+
55+
- name: Upload Package to job as artificat
56+
uses: actions/upload-artifact@v2
57+
with:
58+
name: "Marten.AspNetCore.Identity-${{ steps.gitversion.outputs.nuGetVersionV2 }}"
59+
# Does not support current "working-directory" settings
60+
path: source/output/*.nupkg
61+
if-no-files-found: error
62+
63+
- name: Upload Package to release
64+
# if: contains(github.ref, 'main')
65+
uses: svenstaro/upload-release-action@v1-release
66+
with:
67+
repo_token: ${{ secrets.GITHUB_TOKEN }}
68+
file_glob: true
69+
# Does not support current "working-directory" settings
70+
file: source/output/*.nupkg
71+
tag: "${{ steps.gitversion.outputs.fullSemVer }}"
72+
overwrite: true
73+
74+
- name: Upload Package to nuget
75+
# if: contains(github.ref, 'main')
76+
run: dotnet nuget push ./output/*.nupkg --source $NUGET_FEED --skip-duplicate --api-key ${{ secrets.NUGET_KEY }}

.github/workflows/create_release.yml

Lines changed: 0 additions & 27 deletions
This file was deleted.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<RunSettings>
3+
<DataCollectionRunSettings>
4+
<DataCollectors>
5+
<DataCollector friendlyName="XPlat code coverage">
6+
<Configuration>
7+
<Format>json,cobertura,lcov,teamcity,opencover</Format>
8+
<Exclude>[Marten.AspNetCore.Identity.Tests]*,[Marten.IdentityExampleApp]*</Exclude>
9+
<SingleHit>false</SingleHit>
10+
<UseSourceLink>false</UseSourceLink>
11+
<IncludeTestAssembly>false</IncludeTestAssembly>
12+
<SkipAutoProps>false</SkipAutoProps>
13+
<DeterministicReport>false</DeterministicReport>
14+
</Configuration>
15+
</DataCollector>
16+
</DataCollectors>
17+
</DataCollectionRunSettings>
18+
</RunSettings>

source/Marten.AspNetCore.Identity/Marten.AspNetCore.Identity.csproj

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
<GenerateDocumentationFile>true</GenerateDocumentationFile>
88
<!-- Nuget Package properties -->
9-
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
109
<PackageId>Marten.AspNetCore.Identity</PackageId>
1110
<Authors>Sörnt Poppe</Authors>
1211
<PackageTitle>Marten.AspNetCore.Identity</PackageTitle>
@@ -17,10 +16,9 @@
1716
<PackageTags>aspnetcore marten identity membership</PackageTags>
1817
<RepositoryUrl>https://github.com/soernt/AspNetCore.Identity.Marten</RepositoryUrl>
1918
<RepositoryType>Git</RepositoryType>
20-
<!-- Versioning -->
21-
<PackageVersion>0.1.0</PackageVersion>
22-
<Version>0.1.0</Version>
23-
<FileVersion>0.1.0</FileVersion>
19+
<!--
20+
Versioning will be handled by the GithHub Workflow
21+
-->
2422
</PropertyGroup>
2523

2624
<PropertyGroup>

0 commit comments

Comments
 (0)