-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Start work for issue #2 * config: setup kd-admin tool with various settings * docs: create initial release notes file * config: set version * config: improve nuget pkg setup * chore: complete empty template setup * chore: create template for simple texture rendering and keyboard input * config: update solution file * ide: save run config for velrendertexture template project * ide: update project specific settings * ide: add settings.json file for vscode * ci: create build status check workflow for the VelEmpty template project * ci: create build status check workflow for VelRenderTexture template project * config: add license and readme to the nuget package * docs: update readme * ide: update vscode settings * ci: create release workflow * chore: improve templates
- Loading branch information
1 parent
dfe5183
commit 258657b
Showing
27 changed files
with
694 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,145 @@ | ||
name: 🚀Release | ||
run-name: ${{ vars.PROJECT_NAME }} Production Release ${{ inputs.dry-run == true && '(Dry Run)' || '' }} | ||
|
||
|
||
defaults: | ||
run: | ||
shell: pwsh | ||
|
||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
dry-run: | ||
description: Dry Run - Check to run the workflow without creating a release. | ||
required: false | ||
default: false | ||
type: boolean | ||
|
||
|
||
jobs: | ||
validate_version: | ||
name: Validate Version | ||
uses: KinsonDigital/Infrastructure/.github/workflows/validate-csharp-version.yml@v14.1.0 | ||
with: | ||
project-name: "${{ vars.PROJECT_NAME }}" | ||
release-type: "Production" | ||
secrets: | ||
cicd-pat: "${{ secrets.CICD_TOKEN }}" | ||
|
||
get_release_notes_path: | ||
name: Get Release Notes Dir Path | ||
runs-on: ubuntu-latest | ||
outputs: | ||
release-notes-dir-path: ${{ steps.get-dir-path.outputs.release-notes-dir-path }} | ||
steps: | ||
- name: Get Dir Path | ||
id: get-dir-path | ||
run: | | ||
$dirPath = "${{ vars.PROD_RELATIVE_RELEASE_NOTES_DIR_PATH }}"; | ||
"release-notes-dir-path=$dirPath" >> $env:GITHUB_OUTPUT; | ||
build_vel_empty_template_proj: | ||
name: Build VelEmpty Proj Template | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: "${{ vars.NET_SDK_VERSION }}" | ||
|
||
- name: Build Project | ||
run: | | ||
$projFilePath = "${{ github.workspace }}/VelaptorTemplates/Templates/VelEmpty/VelEmpty.csproj"; | ||
dotnet build $projFilePath -c Release; | ||
build_vel_render_texture_proj: | ||
name: Build VelRenderTexture Proj Template | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: "${{ vars.NET_SDK_VERSION }}" | ||
|
||
- name: Build Project | ||
run: | | ||
$projFilePath = "${{ github.workspace }}/VelaptorTemplates/Templates/VelRenderTexture/VelRenderTexture.csproj"; | ||
dotnet build $projFilePath -c Release; | ||
run_release: | ||
name: Performing Production Release of ${{ vars.PROJECT_NAME }} | ||
needs: [validate_version, get_release_notes_path, build_vel_empty_template_proj, build_vel_render_texture_proj] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: "${{ vars.NET_SDK_VERSION }}" | ||
|
||
- name: Setup Nuget | ||
uses: NuGet/setup-nuget@v2 | ||
|
||
- name: Create Nuget Package | ||
run: | | ||
dotnet pack ` | ||
"${{ github.workspace }}/${{ vars.PROJECT_NAME }}/${{ vars.PROJECT_NAME }}.csproj" ` | ||
-o "${{ github.workspace }}" ` | ||
-c Release ` | ||
-p:IncludeSymbols=true; | ||
- name: Publish Nuget Package | ||
if: ${{ inputs.dry-run == false }} | ||
run: | | ||
$version = "${{ needs.validate_version.outputs.version }}"; | ||
$version = $version.StartsWith("v") ? $version.Substring(1) : $version; | ||
# Push the nuget package | ||
dotnet nuget push ` | ||
"${{ github.workspace }}/${{ vars.ORGANIZATION_NAME }}.${{ vars.PROJECT_NAME }}.$version.nupkg" ` | ||
--api-key ${{ secrets.NUGET_ORG_API_KEY }} ` | ||
--source https://api.nuget.org/v3/index.json; | ||
- name: Create GitHub Release ${{ inputs.dry-run == true && '(Dry Run)' || '' }} | ||
if: ${{ inputs.dry-run == false }} | ||
uses: ncipollo/release-action@v1 | ||
with: | ||
name: "🚀Production - ${{ needs.validate_version.outputs.version }}" | ||
tag: ${{ needs.validate_version.outputs.version }} | ||
owner: ${{ vars.ORGANIZATION_NAME }} | ||
repo: ${{ vars.PROJECT_NAME }} | ||
bodyFile: "${{ github.workspace }}/ReleaseNotes/ProductionReleases/Release-Notes-${{ needs.validate_version.outputs.version }}.md" | ||
artifacts: "${{ github.workspace }}/ReleaseNotes/ProductionReleases/Release-Notes-${{ needs.validate_version.outputs.version }}.md" | ||
prerelease: false | ||
|
||
- name: Set Up Deno | ||
uses: denoland/setup-deno@v2 | ||
with: | ||
deno-version: ${{ vars.DENO_VERSION }} | ||
|
||
- name: Create Script URL | ||
id: script-url | ||
run: | | ||
# Construct the URL to the organizations CICD scripts | ||
$url = "${{ vars.SCRIPT_BASE_URL }}/${{ vars.CICD_SCRIPTS_VERSION }}/${{ vars.SCRIPT_RELATIVE_DIR_PATH }}"; | ||
$url = $url.Replace("\", "/").Replace("//", "/"); | ||
$url = $url.EndsWith("/") ? $url.Substring(0, $url.Length - 1) : $url; | ||
Write-Host "::notice::DotNet Lib Release Script URL: $url"; | ||
"url=$url" >> "$env:GITHUB_OUTPUT"; | ||
- name: Close Milestone | ||
if: ${{ inputs.dry-run == false }} | ||
env: | ||
MILESTONE_NAME: "${{ needs.validate_version.outputs.version }}" | ||
GITHUB_TOKEN: "${{ secrets.CICD_TOKEN }}" | ||
run: deno run -ERN "${{ steps.script-url.outputs.url }}/close-milestone.ts"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: ✅Build Status Check | ||
run-name: ✅Build Status Check (${{ github.base_ref }} branch) | ||
|
||
|
||
defaults: | ||
run: | ||
shell: pwsh | ||
|
||
|
||
on: | ||
pull_request: | ||
branches: [main] | ||
|
||
|
||
jobs: | ||
build_vel_empty_status_check: | ||
name: VelEmpty Proj Template Build Status Check | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: "${{ vars.NET_SDK_VERSION }}" | ||
|
||
- name: Build Project | ||
run: | | ||
$projFilePath = "${{ github.workspace }}/VelaptorTemplates/Templates/VelEmpty/VelEmpty.csproj"; | ||
dotnet build $projFilePath -c Release; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: ✅Build Status Check | ||
run-name: ✅Build Status Check (${{ github.base_ref }} branch) | ||
|
||
|
||
defaults: | ||
run: | ||
shell: pwsh | ||
|
||
|
||
on: | ||
pull_request: | ||
branches: [main] | ||
|
||
|
||
jobs: | ||
build_vel_render_texture_status_check: | ||
name: VelRenderTexture Proj Template Build Status Check | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: "${{ vars.NET_SDK_VERSION }}" | ||
|
||
- name: Build Project | ||
run: | | ||
$projFilePath = "${{ github.workspace }}/VelaptorTemplates/Templates/VelRenderTexture/VelRenderTexture.csproj"; | ||
dotnet build $projFilePath -c Release; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<component name="ProjectRunConfigurationManager"> | ||
<configuration default="false" name="VelRenderTexture" type="DotNetProject" factoryName=".NET Project"> | ||
<option name="EXE_PATH" value="$PROJECT_DIR$/VelaptorTemplates/Templates/VelRenderTexture/bin/Debug/net9.0/VelRenderTexture.exe" /> | ||
<option name="PROGRAM_PARAMETERS" value="" /> | ||
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$/VelaptorTemplates/Templates/VelRenderTexture/bin/Debug/net9.0" /> | ||
<option name="PASS_PARENT_ENVS" value="1" /> | ||
<option name="USE_EXTERNAL_CONSOLE" value="0" /> | ||
<option name="USE_MONO" value="0" /> | ||
<option name="RUNTIME_ARGUMENTS" value="" /> | ||
<option name="PROJECT_PATH" value="$PROJECT_DIR$/VelaptorTemplates/Templates/VelRenderTexture/VelRenderTexture.csproj" /> | ||
<option name="PROJECT_EXE_PATH_TRACKING" value="1" /> | ||
<option name="PROJECT_ARGUMENTS_TRACKING" value="1" /> | ||
<option name="PROJECT_WORKING_DIRECTORY_TRACKING" value="1" /> | ||
<option name="PROJECT_KIND" value="DotNetCore" /> | ||
<option name="PROJECT_TFM" value="net9.0" /> | ||
<method v="2"> | ||
<option name="Build" /> | ||
</method> | ||
</configuration> | ||
</component> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ | ||
"files.exclude": { | ||
"**/.git": true, | ||
"**/.svn": true, | ||
"**/.hg": true, | ||
"**/CVS": true, | ||
"**/.DS_Store": true, | ||
"**/Thumbs.db": true, | ||
".idea": true, | ||
".run": true, | ||
}, | ||
"cSpell.words": [ | ||
"CICD", | ||
"denoland", | ||
"gamedev", | ||
"Kinson", | ||
"ncipollo", | ||
"nupkg", | ||
"pwsh", | ||
"REPONAME", | ||
"Velaptor" | ||
], | ||
"[github-actions-workflow]": { | ||
"editor.tabSize": 2, | ||
"editor.insertSpaces": true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,21 @@ | ||
# VelaptorTemplates | ||
# Velaptor Templates | ||
|
||
Various project templates for game development using [Velaptor](https://github.com/kinsondigital/velaptor). | ||
|
||
For documentation on how to build games using Velaptor, please visit the [Velaptor Documentation](https://docs.velaptor.io). | ||
|
||
Installing the templates can be done using the following dotnet cli command: | ||
```bash | ||
dotnet new install KinsonDigital.VelaptorTemplates | ||
``` | ||
|
||
To create an empty bare-bones Velaptor project, run the following command in your directory of choice: | ||
```bash | ||
dotnet new VelEmpty --name <your-proj-name-here> | ||
``` | ||
|
||
To create a project with basic setup to render a single texture with keyboard input based movement, | ||
run the following command in your directory of choice: | ||
```bash | ||
dotnet new VelRenderTexture --name <your-proj-name-here> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<h1 align="center" style="color: mediumseagreen;font-weight: bold;"> | ||
VelaptorTemplates Production Release Notes - v1.0.0 | ||
</h1> | ||
|
||
Initial Release!! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation"> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=batcher/@EntryIndexedValue">True</s:Boolean> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=gamedev/@EntryIndexedValue">True</s:Boolean> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=kinson/@EntryIndexedValue">True</s:Boolean> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=velaptor/@EntryIndexedValue">True</s:Boolean></wpf:ResourceDictionary> |
10 changes: 10 additions & 0 deletions
10
VelaptorTemplates/Templates/VelEmpty/.template.config/template.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/template", | ||
"author": "KinsonDigital", | ||
"classifications": ["velaptor", "gamedev", "game-dev", "game dev", "velaptor templates"], | ||
"identity": "VelaptorTemplates.VelEmpty", | ||
"name": "Empty Velaptor Project", | ||
"shortName": "VelEmpty", | ||
"sourceName": "VelEmpty", | ||
"preferNameDirectory": true | ||
} |
Oops, something went wrong.