Skip to content

Commit

Permalink
release gh action
Browse files Browse the repository at this point in the history
  • Loading branch information
m-khrapunov committed Jun 29, 2023
1 parent 82e6db8 commit 209d253
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 5 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Release

on:
release:
types: [published]

jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup .NET SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: '7.0.x'

- name: Build
run: dotnet build -c Release
- name: Test
run: dotnet test -c Release --no-build

- name: Publish Demo
run: dotnet publish src/NPokerEngine.Demo/NPokerEngine.Demo.csproj -c Release --output release --nologo
- name: Add .nojekyll file
run: touch release/wwwroot/.nojekyll
- name: Uploading files to gh-pages branch
uses: JamesIves/github-pages-deploy-action@4.1.4
with:
branch: gh-pages
folder: release/wwwroot

- name: Pack nugets
run: dotnet pack src/NPokerEngine/NPokerEngine.csproj -c Release --no-build -p:PackageVersion=${{github.event.release.name}} --output .
- name: Push to NuGet
run: dotnet nuget push "*.nupkg" --api-key ${{secrets.nuget_api_key}} --source https://api.nuget.org/v3/index.json
20 changes: 15 additions & 5 deletions src/NPokerEngine/NPokerEngine.csproj
Original file line number Diff line number Diff line change
@@ -1,9 +1,19 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<LangVersion>9.0</LangVersion>
</PropertyGroup>
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<LangVersion>9.0</LangVersion>
<PackageReadmeFile>readme.md</PackageReadmeFile>
<Company>DigitalAbsurd</Company>
<PackageProjectUrl>https://github.com/miekhra/NPokerEngine</PackageProjectUrl>
<Description>Poker Engine on .NET</Description>
<Authors>miekhra,DigitalAbsurd</Authors>
<PackageTags>poker;holdem;engine</PackageTags>
</PropertyGroup>

<ItemGroup>
<None Include="readme.md" Pack="true" PackagePath="\" />
</ItemGroup>

<ItemGroup>
<InternalsVisibleTo Include="$(AssemblyName).Tests" />
Expand Down
17 changes: 17 additions & 0 deletions src/NPokerEngine/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# NPokerEngine

Poker Engine written on .NET

## Getting started

https://github.com/miekhra/NPokerEngine

## Additional documentation

The engine is rewritten from [PyPokerEngine](https://github.com/ishikota/PyPokerEngine). Tutorial of this project can be used learning how to use engine.

## Feedback

Feel free to create an issues:

- https://github.com/miekhra/NPokerEngine/issues

0 comments on commit 209d253

Please sign in to comment.