Skip to content

Commit

Permalink
feat: Updated.
Browse files Browse the repository at this point in the history
  • Loading branch information
HavenDV committed Sep 1, 2024
1 parent 119c9fd commit 3578682
Show file tree
Hide file tree
Showing 7 changed files with 47 additions and 20 deletions.
29 changes: 25 additions & 4 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
name: Build, test and publish
name: Publish
on:
push:
branches:
- main
paths:
- 'src/**'
- '.github/workflows/**'
tags:
- v**

permissions:
contents: write

jobs:
buind-test-publish:
name: Build, test and publish
publish:
name: Publish
runs-on: windows-latest
steps:
- name: Checkout
Expand Down Expand Up @@ -53,4 +58,20 @@ jobs:
**.nupkg
--skip-duplicate
--source https://api.nuget.org/v3/index.json
--api-key ${{ secrets.NUGET_KEY }}
--api-key ${{ secrets.NUGET_KEY }}

release:
name: Release
runs-on: ubuntu-latest
needs: [publish]
if: startsWith(github.ref, 'refs/tags/v')
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Create release
run: gh release create ${{ github.ref_name }}
--title "${{ github.ref_name }}"
--generate-notes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6 changes: 3 additions & 3 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build and test
name: Test
on:
pull_request:
branches:
Expand All @@ -8,8 +8,8 @@ on:
- '.github/workflows/**'

jobs:
buind-test:
name: Build, test and publish
test:
name: Test
runs-on: windows-latest
steps:
- name: Checkout
Expand Down
13 changes: 12 additions & 1 deletion src/libs/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
</ItemGroup>

<PropertyGroup Label="Nuget">
<Version>1.0.4</Version>
<Description>Modern cross-platform QR code generation, rendering and serialization.</Description>
<PackageTags>qr;qrcode;qrcoder;cross-platform;logo;modern;net8</PackageTags>
<GeneratePackageOnBuild Condition=" '$(Configuration)' == 'Release' ">true</GeneratePackageOnBuild>
Expand All @@ -27,6 +26,18 @@
<None Include="$(MSBuildThisFileDirectory)../../README.md" Pack="true" PackagePath="\" Visible="false" />
</ItemGroup>

<PropertyGroup Label="Versioning">
<MinVerTagPrefix>v</MinVerTagPrefix>
<MinVerDefaultPreReleaseIdentifiers>dev</MinVerDefaultPreReleaseIdentifiers>
</PropertyGroup>

<ItemGroup Label="Versioning">
<PackageReference Include="MinVer" Version="5.0.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>

<ItemGroup Label="Source Link">
<PackageReference Include="DotNet.ReproducibleBuilds" Version="1.2.4">
<PrivateAssets>all</PrivateAssets>
Expand Down
11 changes: 3 additions & 8 deletions src/libs/QrCodes.ImageSharp/QrCodes.ImageSharp.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0;net8.0</TargetFrameworks>
<RootNamespace>QrCodes</RootNamespace>
</PropertyGroup>

Expand All @@ -20,17 +20,12 @@

<ItemGroup Condition=" '$(TargetFramework)' == 'net6.0' ">
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.5" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.0" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'net7.0' ">
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.5" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.0" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.4" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'net8.0' ">
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.5" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.0" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.4" />
</ItemGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions src/libs/QrCodes.SkiaSharp/QrCodes.SkiaSharp.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0;net8.0</TargetFrameworks>
<RootNamespace>QrCodes</RootNamespace>
</PropertyGroup>

Expand All @@ -11,7 +11,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp" Version="2.88.7" />
<PackageReference Include="SkiaSharp" Version="2.88.8" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0-windows;net7.0-windows;net8.0-windows</TargetFrameworks>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0-windows;net8.0-windows</TargetFrameworks>
<RootNamespace>QrCodes</RootNamespace>
</PropertyGroup>

Expand Down
2 changes: 1 addition & 1 deletion src/libs/QrCodes/QrCodes.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net4.6.2;netstandard2.0;net6.0;net8.0</TargetFrameworks>
<NoWarn>$(NoWarn);CA1845;CA1847;CA1308;CA1724;CA1054;CA1055;CA1034;CA1814</NoWarn>
<NoWarn>$(NoWarn);CA1305;CA1307;CA1865;CA1846;CA1863;CA1056;CA1008;CA1031</NoWarn>
</PropertyGroup>
Expand Down

0 comments on commit 3578682

Please sign in to comment.