Skip to content
This repository was archived by the owner on Jul 10, 2024. It is now read-only.

Commit 80dc70e

Browse files
Merge pull request #331 from IvanJosipovic/dev
Misc Updates
2 parents 54d8667 + e1541af commit 80dc70e

File tree

9 files changed

+77
-55
lines changed

9 files changed

+77
-55
lines changed

.github/dependabot.yaml

Lines changed: 0 additions & 14 deletions
This file was deleted.

.github/renovate.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"enabled": true,
3+
"timezone": "America/Vancouver",
4+
"dependencyDashboard": true,
5+
"dependencyDashboardTitle": "Renovate Dashboard",
6+
"commitMessageSuffix": "",
7+
"commitBody": "",
8+
"suppressNotifications": ["prIgnoreNotification"],
9+
"rebaseWhen": "conflicted",
10+
"extends": [
11+
"config:base"
12+
]
13+
}

.github/workflows/cicd.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ on:
33
branches:
44
- '*'
55
- '!master'
6+
- '!beta'
67

78
name: CI/CD
89
jobs:
@@ -38,9 +39,7 @@ jobs:
3839

3940
- name: Get Test Address
4041
run: |
41-
$url = '${{ steps.netlify.outputs.NETLIFY_URL }}';
42-
Write-Output $url;
43-
Set-Content -Path "src/BlazorTable.Tests/BrowserTestsAddress.config" -Value $url;
42+
Set-Content -Path "src/BlazorTable.Tests/BrowserTestsAddress.config" -Value "${{ steps.netlify.outputs.NETLIFY_URL }}";
4443
shell: pwsh
4544

4645
- name: Dotnet Test

.github/workflows/build.yml renamed to .github/workflows/pr.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ on:
22
pull_request:
33
branches:
44
- '*'
5+
56
name: Build
67
jobs:
78
build:

.github/workflows/release.yml

Lines changed: 43 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ on:
22
push:
33
branches:
44
- master
5+
- beta
56

67
name: Create Release
78
jobs:
@@ -13,55 +14,64 @@ jobs:
1314
- name: Checkout code
1415
uses: actions/checkout@v1
1516

16-
- name: Bump version
17-
id: version
18-
uses: anothrNick/[email protected]
19-
env:
20-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
21-
DRY_RUN: true
22-
2317
- name: Setup .NET Core
2418
uses: actions/setup-dotnet@v1
2519
with:
2620
dotnet-version: 3.1.x
2721

28-
- name: Dotnet Pack
29-
working-directory: src/BlazorTable
30-
run: dotnet pack -c Release -p:Version=${{ steps.version.outputs.new_tag }}
31-
32-
- name: Set Test Address
33-
run: |
34-
Set-Content -Path "src/BlazorTable.Tests/BrowserTestsAddress.config" -Value "https://blazortable.netlify.app";
35-
shell: pwsh
36-
37-
- name: Dotnet Test
38-
run: dotnet test --configuration Release
39-
40-
- name: Dotnet Nuget Push
41-
if: "!contains(github.event.head_commit.message, '#skip')"
42-
working-directory: src/BlazorTable/bin/Release
43-
run: dotnet nuget push BlazorTable.*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NUGET_API_KEY }}
44-
continue-on-error: true
45-
4622
- name: Dotnet Publish
4723
working-directory: src/BlazorTable.Sample.Wasm
4824
run: dotnet publish -c Release
4925

5026
- name: Deploy to Production
27+
if: github.ref == 'refs/heads/master'
28+
id: netlify
5129
uses: netlify/actions/cli@master
5230
with:
5331
args: deploy --prod --json -d src/BlazorTable.Sample.Wasm/bin/Release/netstandard2.1/publish/wwwroot
5432
env:
5533
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
5634
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
5735

58-
- name: Create Release
59-
if: "!contains(github.event.head_commit.message, '#skip')"
60-
uses: actions/create-release@master
36+
- name: Set Test Address
37+
if: github.ref == 'refs/heads/master'
38+
run: |
39+
Set-Content -Path "src/BlazorTable.Tests/BrowserTestsAddress.config" -Value "${{ steps.netlify.outputs.NETLIFY_URL }}";
40+
shell: pwsh
41+
42+
- name: Deploy to Staging
43+
if: github.ref == 'refs/heads/beta'
44+
id: netlify2
45+
uses: netlify/actions/cli@master
46+
with:
47+
args: deploy --json -d src/BlazorTable.Sample.Wasm/bin/Release/netstandard2.1/publish/wwwroot
6148
env:
62-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
49+
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
50+
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
51+
52+
- name: Set Test Address
53+
if: github.ref == 'refs/heads/beta'
54+
run: |
55+
Set-Content -Path "src/BlazorTable.Tests/BrowserTestsAddress.config" -Value "${{ steps.netlify2.outputs.NETLIFY_URL }}";
56+
shell: pwsh
57+
58+
- name: Dotnet Test
59+
run: dotnet test --configuration Release
60+
61+
- name: Semantic Release
62+
uses: cycjimmy/semantic-release-action@v2
63+
id: semantic
6364
with:
64-
tag_name: v${{ steps.version.outputs.new_tag }}
65-
release_name: Release ${{ steps.version.outputs.new_tag }}
66-
draft: false
67-
prerelease: false
65+
semantic_version: 17.4
66+
env:
67+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
68+
69+
- name: Dotnet Pack
70+
if: steps.semantic.outputs.new_release_published == 'true'
71+
working-directory: src/BlazorTable
72+
run: dotnet pack -c Release -p:Version=${{ steps.version.outputs.new_tag }}
73+
74+
- name: Dotnet Nuget Push
75+
if: steps.semantic.outputs.new_release_published == 'true'
76+
working-directory: src/BlazorTable/bin/Release
77+
run: dotnet nuget push BlazorTable.*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NUGET_API_KEY }}

.releaserc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"plugins": [
3+
"@semantic-release/commit-analyzer",
4+
"@semantic-release/release-notes-generator",
5+
"@semantic-release/github"
6+
]
7+
}

global.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"sdk": {
3+
"version": "3.1.404",
4+
"rollForward": "latestFeature"
5+
}
6+
}

src/BlazorTable.Tests/BlazorTable.Tests.csproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@
77
</PropertyGroup>
88

99
<ItemGroup>
10-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.8.3" />
11-
<PackageReference Include="PuppeteerSharp" Version="2.0.4" />
12-
<PackageReference Include="PuppeteerSharp.Contrib.Extensions" Version="3.0.0" />
10+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.10.0" />
11+
<PackageReference Include="PuppeteerSharp" Version="5.0.0" />
12+
<PackageReference Include="PuppeteerSharp.Contrib.Extensions" Version="4.0.0" />
1313
<PackageReference Include="Shouldly" Version="4.0.3" />
1414
<PackageReference Include="xunit" Version="2.4.1" />
1515
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
1616
<PrivateAssets>all</PrivateAssets>
1717
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1818
</PackageReference>
19-
<PackageReference Include="coverlet.collector" Version="3.0.2">
19+
<PackageReference Include="coverlet.collector" Version="3.1.0">
2020
<PrivateAssets>all</PrivateAssets>
2121
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
2222
</PackageReference>

src/BlazorTable.Tests/BrowserTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public async Task InitializeAsync()
2424
else
2525
throw new Exception($"Missing {filename}");
2626

27-
await new BrowserFetcher().DownloadAsync(BrowserFetcher.DefaultRevision);
27+
await new BrowserFetcher().DownloadAsync(BrowserFetcher.DefaultChromiumRevision);
2828

2929
Browser = await Puppeteer.LaunchAsync(new LaunchOptions
3030
{

0 commit comments

Comments
 (0)