Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
aschuhardt committed Jan 6, 2024
2 parents 7c3adfa + 535a595 commit 4a62778
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 30 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Build and Publish
on:
workflow_run:
workflows: [ Build ]
types:
- completed
branches: [ main, beta ]
jobs:
version:
name: Calculate Version
runs-on: ubuntu-latest
outputs:
semVer: ${{ steps.gitversion.outputs.semVer }}
assemblySemVer: ${{ steps.gitversion.outputs.assemblySemVer }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v0
with:
versionSpec: '5.x'
- name: Determine Version
id: gitversion
uses: gittools/actions/gitversion/execute@v0
build:
name: Build and Publish
runs-on: ubuntu-latest
needs: [ version ]
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 7.0.x
- name: Build
run: dotnet build ./Opal/Opal.csproj -c Release -p:AssemblyVersion="${{ needs.version.outputs.assemblySemVer }}"
- name: Pack
run: dotnet pack ./Opal/Opal.csproj --no-build -c Release -o . -p:Version="${{ needs.version.outputs.semVer }}"
- name: Publish Library
run: dotnet nuget push *.nupkg -k ${{ secrets.NUGETAPIKEY }} --skip-duplicate -n -s https://api.nuget.org/v3/index.json
- name: Publish Symbols
run: dotnet nuget push *.snupkg -k ${{ secrets.NUGETAPIKEY }} --skip-duplicate -n -s https://api.nuget.org/v3/index.json
22 changes: 9 additions & 13 deletions .github/workflows/dotnet.yml → .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: .NET

name: Test
on:
push:
branches: [ main, beta ]
Expand All @@ -8,21 +7,18 @@ on:
- '**/*.gitignore'
- '**/*.gitattributes'
workflow_dispatch:

jobs:
build:

test:
strategy:
matrix:
framework: [ netstandard2.0, net7.0, net8.0 ]
runs-on: ubuntu-latest

name: Test
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 7.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal
dotnet-version: 8.0.x
- name: Run Tests
run: dotnet test -f ${{ matrix.framework }
4 changes: 1 addition & 3 deletions Opal.Test/Opal.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<Nullable>enable</Nullable>

<TargetFrameworks>net6.0</TargetFrameworks>
<IsPackable>false</IsPackable>
</PropertyGroup>

Expand Down
23 changes: 11 additions & 12 deletions Opal/Opal.csproj
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<ImplicitUsings>disable</ImplicitUsings>
<Authors>Addison Schuhardt</Authors>
<Description>A client library for the Gemini and Titan protocols</Description>
<PackageProjectUrl>https://github.com/aschuhardt/Opal</PackageProjectUrl>
<RepositoryUrl>https://github.com/aschuhardt/Opal</RepositoryUrl>
<PackageTags>gemini;gemini-protocol;titan;titan-protocol;client</PackageTags>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<PackageVersion>1.7.2</PackageVersion>
<TargetFrameworks>net7.0;net6.0;netstandard2.0</TargetFrameworks>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<PackageReadmeFile>README.md</PackageReadmeFile>
<ImplicitUsings>disable</ImplicitUsings>
<Authors>Addison Schuhardt</Authors>
<Description>A client library for the Gemini and Titan protocols</Description>
<PackageProjectUrl>https://github.com/aschuhardt/Opal</PackageProjectUrl>
<RepositoryUrl>https://github.com/aschuhardt/Opal</RepositoryUrl>
<PackageTags>gemini;gemini-protocol;titan;titan-protocol;TLS</PackageTags>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<TargetFrameworks>net6.0;net7.0;net8.0;netstandard2.0</TargetFrameworks>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<PackageReadmeFile>README.md</PackageReadmeFile>
</PropertyGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
![Opal on Nuget](https://img.shields.io/nuget/v/Opal) ![Opal build](https://img.shields.io/github/actions/workflow/status/aschuhardt/Opal/dotnet.yml?branch=main) ![Last commit](https://img.shields.io/github/last-commit/aschuhardt/Opal) ![MIT](https://img.shields.io/github/license/aschuhardt/Opal)

# Opal
A client library for the Gemini and Titan protocols targeting .NET Standard 2.0, .NET 6, and .NET 7
A client library for the Gemini and Titan protocols targeting .NET Standard 2.0 and .NET 7

## Features
- Asynchronous requests
Expand All @@ -16,7 +16,7 @@ A client library for the Gemini and Titan protocols targeting .NET Standard 2.0,
Install the Nuget package

```
Install-Package Opal -Version 1.7.1
Install-Package Opal -Version 1.7.4
```

Create an instance of a client and make requests
Expand Down

0 comments on commit 4a62778

Please sign in to comment.