Skip to content

Commit c9cf188

Browse files
committed
feature: add sixpack
1 parent 5c5dfc5 commit c9cf188

File tree

9 files changed

+181
-20
lines changed

9 files changed

+181
-20
lines changed

.github/release-drafter.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name-template: '$RESOLVED_VERSION'
2+
tag-template: '$RESOLVED_VERSION'
3+
template: |
4+
# What's Changed
5+
6+
$CHANGES
7+
8+
**Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...$RESOLVED_VERSION
9+
10+
categories:
11+
- title: 'Changes'
12+
labels:
13+
- 'feature'
14+
- 'feat'
15+
16+
- title: 'Bug Fixes'
17+
labels:
18+
- 'bug'
19+
- 'fix'
20+
21+
version-resolver:
22+
major:
23+
labels:
24+
- 'type: breaking'
25+
minor:
26+
labels:
27+
- 'type: feature'
28+
patch:
29+
labels:
30+
- 'type: bug'
31+
- 'type: maintenance'
32+
- 'type: docs'
33+
- 'type: dependencies'
34+
- 'type: security'
35+
36+
exclude-labels:
37+
- 'skip-changelog'

.github/workflows/dotnet.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
runs-on: ${{ matrix.os }}
1919
strategy:
2020
matrix:
21-
dotnet-version: [ '7.0.x' ]
21+
dotnet-version: [ '7.x' ]
2222
os: [ windows-latest, ubuntu-latest, macos-latest ]
2323

2424
steps:

.github/workflows/on-tag-do-release.yml

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

.github/workflows/release.yml

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
2+
name: Release
3+
on:
4+
push:
5+
tags:
6+
- '[0-9]+.[0-9]+.[0-9]+'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v3
15+
16+
- name: Setup Dotnet
17+
uses: actions/setup-dotnet@v3
18+
with:
19+
dotnet-version: '7.x'
20+
21+
- name: restore dependencies
22+
run: dotnet restore
23+
24+
- name: build
25+
run: dotnet build -c Release --no-restore
26+
27+
- name: publish
28+
run: dotnet publish src/DotFastLZ.SixPack -c Release --no-restore --no-self-contained --output working-temp
29+
30+
- name: version
31+
id: version
32+
run: |
33+
tag=${GITHUB_REF/refs\/tags\//}
34+
version=${tag}
35+
major=${version%%.*}
36+
echo "tag=${tag}" >> $GITHUB_OUTPUT
37+
echo "version=${version}" >> $GITHUB_OUTPUT
38+
echo "major=${major}" >> $GITHUB_OUTPUT
39+
40+
- name: Zip
41+
working-directory: ${{ env.working-directory }}
42+
run: |
43+
cp -rfv resources working-temp
44+
cd working-temp
45+
echo "dotnet DotFastLZ.SixPack.dll" > run.bat
46+
zip -r ../DotFastLZ.SixPack-${{ steps.version.outputs.version}}.zip ./
47+
if: success()
48+
49+
- uses: release-drafter/release-drafter@master
50+
with:
51+
version: ${{ steps.version.outputs.version }}
52+
publish: true
53+
env:
54+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
55+
56+
- name: zip Upload
57+
uses: softprops/action-gh-release@v1
58+
with:
59+
files: |
60+
DotFastLZ.SixPack-${{ steps.version.outputs.version}}.zip
61+
env:
62+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
63+
64+

DotFastLZ.sln

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "test", "test", "{87EE9A81-1
1111
EndProject
1212
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DotFastLZ.Compression.Tests", "test\DotFastLZ.Compression.Tests\DotFastLZ.Compression.Tests.csproj", "{FD482722-B4F3-4D05-8AAA-8EA228888C05}"
1313
EndProject
14+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DotFastLZ.SixPack", "src\DotFastLZ.SixPack\DotFastLZ.SixPack.csproj", "{98630365-E9A4-4715-B08F-E6658FDD3155}"
15+
EndProject
16+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DotFastLZ.SixPack.Tests", "test\DotFastLZ.SixPack.Tests\DotFastLZ.SixPack.Tests.csproj", "{0FEC3B0A-D900-4066-A652-25C392004B16}"
17+
EndProject
1418
Global
1519
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1620
Debug|Any CPU = Debug|Any CPU
@@ -28,9 +32,19 @@ Global
2832
{FD482722-B4F3-4D05-8AAA-8EA228888C05}.Debug|Any CPU.Build.0 = Debug|Any CPU
2933
{FD482722-B4F3-4D05-8AAA-8EA228888C05}.Release|Any CPU.ActiveCfg = Release|Any CPU
3034
{FD482722-B4F3-4D05-8AAA-8EA228888C05}.Release|Any CPU.Build.0 = Release|Any CPU
35+
{98630365-E9A4-4715-B08F-E6658FDD3155}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
36+
{98630365-E9A4-4715-B08F-E6658FDD3155}.Debug|Any CPU.Build.0 = Debug|Any CPU
37+
{98630365-E9A4-4715-B08F-E6658FDD3155}.Release|Any CPU.ActiveCfg = Release|Any CPU
38+
{98630365-E9A4-4715-B08F-E6658FDD3155}.Release|Any CPU.Build.0 = Release|Any CPU
39+
{0FEC3B0A-D900-4066-A652-25C392004B16}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
40+
{0FEC3B0A-D900-4066-A652-25C392004B16}.Debug|Any CPU.Build.0 = Debug|Any CPU
41+
{0FEC3B0A-D900-4066-A652-25C392004B16}.Release|Any CPU.ActiveCfg = Release|Any CPU
42+
{0FEC3B0A-D900-4066-A652-25C392004B16}.Release|Any CPU.Build.0 = Release|Any CPU
3143
EndGlobalSection
3244
GlobalSection(NestedProjects) = preSolution
3345
{C20491BC-E472-4F09-B29C-DD7BF853C1C4} = {642F4CE7-0431-49D4-9BDE-E663C13C7792}
3446
{FD482722-B4F3-4D05-8AAA-8EA228888C05} = {87EE9A81-1074-4466-AF83-6A059185A8E9}
47+
{98630365-E9A4-4715-B08F-E6658FDD3155} = {642F4CE7-0431-49D4-9BDE-E663C13C7792}
48+
{0FEC3B0A-D900-4066-A652-25C392004B16} = {87EE9A81-1074-4466-AF83-6A059185A8E9}
3549
EndGlobalSection
3650
EndGlobal
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<OutputType>Exe</OutputType>
5+
<TargetFramework>net7.0</TargetFramework>
6+
<Nullable>enable</Nullable>
7+
</PropertyGroup>
8+
9+
<ItemGroup>
10+
<ProjectReference Include="..\DotFastLZ.Compression\DotFastLZ.Compression.csproj" />
11+
</ItemGroup>
12+
13+
</Project>

src/DotFastLZ.SixPack/Program.cs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
using System;
2+
3+
namespace DotFastLZ.SixPack;
4+
5+
public static class Program
6+
{
7+
public static int Main(string[] args)
8+
{
9+
// See https://aka.ms/new-console-template for more information
10+
Console.WriteLine("Hello, World!");
11+
return 0;
12+
}
13+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<TargetFramework>net7.0</TargetFramework>
5+
<Nullable>enable</Nullable>
6+
<IsPackable>false</IsPackable>
7+
<IsTestProject>true</IsTestProject>
8+
</PropertyGroup>
9+
10+
<ItemGroup>
11+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.2" />
12+
<PackageReference Include="NUnit" Version="3.13.3" />
13+
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0" />
14+
<PackageReference Include="NUnit.Analyzers" Version="3.7.0" />
15+
<PackageReference Include="coverlet.collector" Version="6.0.0" />
16+
</ItemGroup>
17+
18+
<ItemGroup>
19+
<ProjectReference Include="..\..\src\DotFastLZ.SixPack\DotFastLZ.SixPack.csproj" />
20+
</ItemGroup>
21+
22+
</Project>
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
using NUnit.Framework;
2+
3+
namespace DotFastLZ.SixPack.Tests;
4+
5+
public class Tests
6+
{
7+
[SetUp]
8+
public void Setup()
9+
{
10+
}
11+
12+
[Test]
13+
public void Test1()
14+
{
15+
Assert.Pass();
16+
}
17+
}

0 commit comments

Comments
 (0)