C7-Game / Prototype

An early-stage, open-source 4X strategy game
https://c7-game.github.io/
MIT License
34 stars 9 forks source link

Build Server Uses .Net 6.0, and DRY Out GitHub Actions Code #310

Closed QuintillusCFC closed 2 years ago

QuintillusCFC commented 2 years ago

Closes #307

Closes #309

GitHub Actions isn't the world's most advanced CI product, but I still managed to DRY it out after some research on how to do that. See #309 for more details about that. This currently uses Composite Actions, which seemed like the most appropriate tool for the job, although I'm still not entirely convinced just building for all 3 platforms in one job wouldn't be a superior (if perhaps slightly slower) approach.

QuintillusCFC commented 2 years ago

Okay, I'm marking this as ready. The first commit does the .NET 6.0 part. The remainders are DRYing out the code, there's a commit for each Workflow build. No need to look at each one individually as most got reverted, but if you're curious what was tried, you can see the answer.

Basically it's still not as DRY as I'd like (mainly due to required boilerplate), but my net lines of code is still negative so I think it's good enough for now. My goal here isn't to be an expert on GitHub Actions, and after last month's Serilog tangents, I'd prefer to keep this tangent short.

pcen commented 2 years ago

looks like I can rebase #204 on this since the approach I took was pretty hacky, but it would be great to get unit tests running in CI

QuintillusCFC commented 2 years ago

Merging after 7+ days with no-review, and self-checking.