Skip to content

Commit 8ef0263

Browse files
Update dependencies, modernize samples, and target .NET 8 for testing (#1)
* upgrade all dependencies to latest stable versions Agent-Logs-Url: https://github.com/bhavishyachandra/Hangfire.Tags/sessions/9eeadfa2-164e-4547-b992-59d18893ab46 Co-authored-by: bhavishyachandra <10553920+bhavishyachandra@users.noreply.github.com> * net48 support: add net48 TFM to Mongo lib + modernize Hangfire.MvcApplication sample Agent-Logs-Url: https://github.com/bhavishyachandra/Hangfire.Tags/sessions/096e07e4-8e13-4788-b647-04401df5f094 Co-authored-by: bhavishyachandra <10553920+bhavishyachandra@users.noreply.github.com> * Rebrand packages to Hangtools and add NuGet publish workflow * Update NuGet publish workflow to use OIDC via NuGet/login --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: bhavishyachandra <10553920+bhavishyachandra@users.noreply.github.com> Co-authored-by: bhavishyachandra <bhavishyachandra@gmail.com>
1 parent 016a74c commit 8ef0263

21 files changed

Lines changed: 179 additions & 561 deletions

File tree

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: Publish NuGet
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags:
7+
- "v*"
8+
9+
jobs:
10+
publish:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
id-token: write # enable GitHub OIDC token issuance for this job
14+
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
19+
- name: Setup .NET
20+
uses: actions/setup-dotnet@v4
21+
with:
22+
dotnet-version: "8.0.x"
23+
24+
- name: Restore
25+
run: dotnet restore Hangfire.Tags.sln
26+
27+
- name: Build
28+
run: dotnet build Hangfire.Tags.sln -c Release --no-restore /p:ContinuousIntegrationBuild=true
29+
30+
- name: Test
31+
run: |
32+
dotnet test tests/FaceIT.Hangfire.Tags.Tests/FaceIT.Hangfire.Tags.Tests.csproj -c Release --no-build
33+
dotnet test tests/FaceIT.Hangfire.Tags.PostgreSql.Tests/FaceIT.Hangfire.Tags.PostgreSql.Tests.csproj -c Release --no-build
34+
dotnet test tests/FaceIT.Hangfire.Tags.MySql.Tests/FaceIT.Hangfire.Tags.MySql.Tests.csproj -c Release --no-build
35+
36+
- name: Pack
37+
run: dotnet pack Hangfire.Tags.sln -c Release -o artifacts --no-build /p:ContinuousIntegrationBuild=true
38+
39+
- name: NuGet Sign-in (OIDC to Temp API Key)
40+
uses: NuGet/login@v1
41+
id: nuget-login
42+
with:
43+
user: hangtools
44+
45+
- name: Publish packages
46+
run: |
47+
shopt -s nullglob
48+
for pkg in artifacts/*.nupkg; do
49+
if [[ "$pkg" == *.snupkg ]]; then
50+
continue
51+
fi
52+
dotnet nuget push "$pkg" \
53+
--api-key "${{ steps.nuget-login.outputs.NUGET_API_KEY }}" \
54+
--source "https://api.nuget.org/v3/index.json" \
55+
--skip-duplicate
56+
done
57+
58+
- name: Publish symbol packages
59+
run: |
60+
shopt -s nullglob
61+
for spkg in artifacts/*.snupkg; do
62+
dotnet nuget push "$spkg" \
63+
--api-key "${{ steps.nuget-login.outputs.NUGET_API_KEY }}" \
64+
--source "https://api.nuget.org/v3/index.json" \
65+
--skip-duplicate
66+
done

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Hangfire.Tags
22

33
[![Build status](https://ci.appveyor.com/api/projects/status/hqrtav24894dtjcp/branch/main?svg=true)](https://ci.appveyor.com/project/faceit/hangfire-tags/branch/main)
4-
[![NuGet](https://img.shields.io/nuget/v/FaceIT.Hangfire.Tags.svg)](https://www.nuget.org/packages/FaceIT.Hangfire.Tags/)
4+
[![NuGet](https://img.shields.io/nuget/v/Hangtools.Hangfire.Tags.svg)](https://www.nuget.org/packages/Hangtools.Hangfire.Tags/)
55
![MIT License](https://img.shields.io/badge/license-MIT-orange.svg)
66
[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=HYKKSJL8B7XE4&currency_code=EUR&source=url)
77

8-
Inspired by the lack of searching and grouping, Hangfire.Tags provides a way to search and group different jobs.
8+
Inspired by the lack of searching and grouping, Hangfire.Tags provides a way to search and group different jobs.
99

1010
![sidemenu](https://raw.githubusercontent.com/face-it/Hangfire.Tags/main/Sidemenu-dark.png)
1111
![dashboard](https://raw.githubusercontent.com/face-it/Hangfire.Tags/main/Dashboard.png)
@@ -59,6 +59,7 @@ GlobalConfiguration.Configuration
5959
you'll need to call `UseTags()`, `UseTagsWithSql()`, `UseTagsWithPostgreSql()`, `UseTagsWithMySql()` or `UseTagsWithRedis()` on both.
6060

6161
### Sql Options
62+
6263
If you have a custom HangFire schema in your database, you'll need to pass your sql options to your storage method. For example:
6364

6465
```csharp

samples/Hangfire.Core.MvcApplication/Hangfire.Core.MvcApplication.csproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
<Project Sdk="Microsoft.NET.Sdk.Web">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net8.0</TargetFramework>
55
<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel>
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<PackageReference Include="Hangfire" Version="1.8.15" />
10-
<PackageReference Include="Hangfire.Heartbeat" Version="0.5.1" />
11-
<PackageReference Include="Hangfire.Mongo" Version="1.9.6" />
9+
<PackageReference Include="Hangfire" Version="1.8.23" />
10+
<PackageReference Include="Hangfire.Heartbeat" Version="0.6.0" />
11+
<PackageReference Include="Hangfire.Mongo" Version="1.15.0" />
1212
<PackageReference Include="Hangfire.MySqlStorage" Version="2.0.3" />
13-
<PackageReference Include="Hangfire.PostgreSql" Version="1.20.0" />
14-
<PackageReference Include="Microsoft.Data.SqlClient" Version="5.1.3" />
13+
<PackageReference Include="Hangfire.PostgreSql" Version="1.21.1" />
14+
<PackageReference Include="Microsoft.Data.SqlClient" Version="7.0.1" />
1515
</ItemGroup>
1616

1717
<ItemGroup>

0 commit comments

Comments
 (0)