mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2025-12-13 01:58:30 +00:00
commit
77acf01a12
60
.github/workflows/ci.yml
vendored
Normal file
60
.github/workflows/ci.yml
vendored
Normal file
@ -0,0 +1,60 @@
|
||||
name: RGB.NET-CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ Development ]
|
||||
paths:
|
||||
- '**.cs'
|
||||
- '**.csproj'
|
||||
- '**.yml'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: windows-2022
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v1
|
||||
with:
|
||||
dotnet-version: 6.0.x
|
||||
- name: Git Semantic Version
|
||||
id: versioning
|
||||
uses: PaulHatch/semantic-version@v4.0.3
|
||||
with:
|
||||
short_tags: false
|
||||
- name: Restore dependencies
|
||||
run: dotnet restore
|
||||
- name: Build
|
||||
run: dotnet build --no-restore --configuration Release /p:Version=${{ steps.versioning.outputs.version }}
|
||||
- name: Test
|
||||
run: dotnet test --no-build --verbosity normal --configuration Release
|
||||
- name: Upload a Build Artifact NET5
|
||||
uses: actions/upload-artifact@v2.2.4
|
||||
with:
|
||||
name: RGB.NET-NET5
|
||||
path: bin/net5.0/RGB.NET.*.dll
|
||||
if-no-files-found: error
|
||||
- name: Upload a Build Artifact NET6
|
||||
uses: actions/upload-artifact@v2.2.4
|
||||
with:
|
||||
name: RGB.NET-NET6
|
||||
path: bin/net6.0/RGB.NET.*.dll
|
||||
if-no-files-found: error
|
||||
- name: Upload Nuget Build Artifact
|
||||
uses: actions/upload-artifact@v2.2.4
|
||||
with:
|
||||
name: RGB.NET-Nugets
|
||||
path: bin/*nupkg
|
||||
if-no-files-found: error
|
||||
- name: Nuget Push
|
||||
run: dotnet nuget push "bin/*.nupkg" --skip-duplicate --api-key ${NUGET_TOKEN}
|
||||
env:
|
||||
NUGET_TOKEN: ${{ secrets.NUGET_TOKEN }}
|
||||
- name: Nuget Push Symbols
|
||||
run: dotnet nuget push "bin/*.snupkg" --skip-duplicate --api-key ${NUGET_TOKEN}
|
||||
env:
|
||||
NUGET_TOKEN: ${{ secrets.NUGET_TOKEN }}
|
||||
24
.github/workflows/pr_verify.yml
vendored
Normal file
24
.github/workflows/pr_verify.yml
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
name: PR-Verify
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: [ master, Development ]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: windows-2022
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v1
|
||||
with:
|
||||
dotnet-version: 6.0.x
|
||||
- name: Restore dependencies
|
||||
run: dotnet restore
|
||||
- name: Build
|
||||
run: dotnet build --no-restore --configuration Release /p:Version=0.0.0
|
||||
- name: Test
|
||||
run: dotnet test --no-build --verbosity normal --configuration Release
|
||||
|
||||
66
.github/workflows/release.yml
vendored
Normal file
66
.github/workflows/release.yml
vendored
Normal file
@ -0,0 +1,66 @@
|
||||
name: RGB.NET-Release
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
paths:
|
||||
- '**.cs'
|
||||
- '**.csproj'
|
||||
- '**.yml'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: windows-2022
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v1
|
||||
with:
|
||||
dotnet-version: 6.0.x
|
||||
- name: Git Semantic Version
|
||||
id: versioning
|
||||
uses: PaulHatch/semantic-version@v4.0.3
|
||||
with:
|
||||
short_tags: false
|
||||
format: "${major}.${minor}.${patch}"
|
||||
- name: Restore dependencies
|
||||
run: dotnet restore
|
||||
- name: Build
|
||||
run: dotnet build --no-restore --configuration Release /p:Version=${{ steps.versioning.outputs.version }}
|
||||
- name: Test
|
||||
run: dotnet test --no-build --verbosity normal --configuration Release
|
||||
- name: Upload a Build Artifact NET5
|
||||
uses: actions/upload-artifact@v2.2.4
|
||||
with:
|
||||
name: RGB.NET-NET5
|
||||
path: bin/net5.0/RGB.NET.*.dll
|
||||
if-no-files-found: error
|
||||
- name: Upload a Build Artifact NET6
|
||||
uses: actions/upload-artifact@v2.2.4
|
||||
with:
|
||||
name: RGB.NET-NET6
|
||||
path: bin/net6.0/RGB.NET.*.dll
|
||||
if-no-files-found: error
|
||||
- name: Upload Nuget Build Artifact
|
||||
uses: actions/upload-artifact@v2.2.4
|
||||
with:
|
||||
name: RGB.NET-Nugets
|
||||
path: bin/*nupkg
|
||||
if-no-files-found: error
|
||||
- name: Release
|
||||
uses: softprops/action-gh-release@v1
|
||||
with:
|
||||
tag_name: ${{ steps.versioning.outputs.version_tag }}
|
||||
generate_release_notes: true
|
||||
files: bin/net6.0/RGB.NET.*.dll
|
||||
- name: Nuget Push
|
||||
run: dotnet nuget push "bin/*.nupkg" --skip-duplicate --api-key ${NUGET_TOKEN}
|
||||
env:
|
||||
NUGET_TOKEN: ${{ secrets.NUGET_TOKEN }}
|
||||
- name: Nuget Push Symbols
|
||||
run: dotnet nuget push "bin/*.snupkg" --skip-duplicate --api-key ${NUGET_TOKEN}
|
||||
env:
|
||||
NUGET_TOKEN: ${{ secrets.NUGET_TOKEN }}
|
||||
Loading…
x
Reference in New Issue
Block a user