Skip to content

Commit 1c4ed60

Browse files
Merge pull request #42 from AristurtleDev/release/1.9.1
Release/1.9.1
2 parents 399577c + 6053802 commit 1c4ed60

4 files changed

Lines changed: 100 additions & 63 deletions

File tree

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
################################################################################
2+
### Build AsepriteDotNet (Release)
3+
### Builds, tests, and packs the AsepriteDotNet source libraries.
4+
### Once the build job finishes, the deploy job uploads the nupkg files to NuGet.
5+
###
6+
### - Can be triggered manually with workflow_dispatch
7+
### - Allows specifying a branch (defaults to develop)
8+
### - Version numbers are determined by the project properties on the branch
9+
################################################################################
10+
name: "Create Release"
11+
12+
on:
13+
workflow_dispatch:
14+
inputs:
15+
branch:
16+
description: 'Branch to build from (e.g., main, develop)'
17+
required: true
18+
type: string
19+
default: 'develop'
20+
21+
jobs:
22+
build:
23+
name: "Build AsepriteDotNet"
24+
runs-on: ubuntu-latest
25+
26+
steps:
27+
- name: Clone Repository
28+
uses: actions/checkout@v4
29+
with:
30+
ref: ${{ inputs.branch }}
31+
32+
- name: Setup Dotnet
33+
uses: actions/setup-dotnet@v4
34+
with:
35+
dotnet-version: 8.0.x
36+
37+
- name: Build AsepriteDotNet
38+
run: dotnet build source/AsepriteDotNet/AsepriteDotNet.csproj --nologo --verbosity minimal --configuration Release
39+
40+
- name: Test AsepriteDotNet
41+
run: dotnet test tests/AsepriteDotNet.Tests/AsepriteDotNet.Tests.csproj --nologo --verbosity minimal --configuration Release
42+
43+
- name: Pack AsepriteDotNet
44+
run: dotnet pack source/AsepriteDotNet/AsepriteDotNet.csproj --nologo --verbosity minimal --configuration Release
45+
46+
- name: Upload Artifacts
47+
uses: actions/upload-artifact@v4
48+
with:
49+
name: build-artifacts
50+
path: ./.artifacts/src/**/*.nupkg
51+
52+
deploy:
53+
name: "Deploy NuGets"
54+
runs-on: ubuntu-latest
55+
needs: [ build ]
56+
permissions:
57+
contents: write
58+
59+
steps:
60+
- name: Download Artifacts
61+
uses: actions/download-artifact@v4
62+
with:
63+
name: build-artifacts
64+
path: ./.artifacts
65+
66+
- name: Push Packages to NuGet
67+
env:
68+
NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }}
69+
run: |
70+
for PACKAGE in .artifacts/**/*.nupkg; do
71+
dotnet nuget push "$PACKAGE" --source https://api.nuget.org/v3/index.json --skip-duplicate --api-key "$NUGET_API_KEY"
72+
done

.github/workflows/main.yml

Lines changed: 0 additions & 62 deletions
This file was deleted.
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
################################################################################
2+
### Pull Request Validation
3+
### Runs unit tests on pull requests targeting the develop branch.
4+
################################################################################
5+
name: "Pull Request Validation"
6+
7+
on:
8+
pull_request:
9+
branches:
10+
- develop
11+
12+
jobs:
13+
test:
14+
name: "Run Tests"
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Clone Repository
19+
uses: actions/checkout@v4
20+
21+
- name: Setup Dotnet
22+
uses: actions/setup-dotnet@v4
23+
with:
24+
dotnet-version: 8.0.x
25+
26+
- name: Test AsepriteDotNet
27+
run: dotnet test tests/AsepriteDotNet.Tests/AsepriteDotNet.Tests.csproj --nologo --verbosity minimal --configuration Release

Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<NeutralLanguage>en</NeutralLanguage>
2121
<ImplicitUsings>enable</ImplicitUsings>
2222
<Nullable>enable</Nullable>
23-
<Version>1.9.0</Version>
23+
<Version>1.9.1</Version>
2424
</PropertyGroup>
2525

2626
<!-- Setup Code Analysis using the .editorconfig file -->

0 commit comments

Comments
 (0)