Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Finish "chore: update .NET Framework version" #4

Closed
wants to merge 13 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/version.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
mode: ContinuousDeployment
branches:
master:
tag: beta
hotfix:
tag: useBranchName
82 changes: 82 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
name: Release

on:
push:
tags:
- "*"

jobs:
calculate-version:
name: Calculate Version
runs-on: ubuntu-latest
outputs:
semVer: ${{ steps.gitversion.outputs.semVer }}

steps:
- uses: actions/[email protected]
with:
fetch-depth: 0

- name: Install GitVersion
uses: gittools/actions/gitversion/[email protected]
with:
versionSpec: "5.x"

- name: Determine Version
id: gitversion
uses: gittools/actions/gitversion/[email protected]
with:
useConfigFile: true
configFilePath: ./.github/GitVersion.yml

build:
name: Build and Release
runs-on: windows-latest
needs: calculate-version
env:
SEMVER: ${{ needs.calculate-version.outputs.semVer }}
ZipName: NFive.SDK.Core-${{ needs.calculate-version.outputs.semVer }}.zip

steps:
- uses: actions/[email protected]

- name: Setup MSBuild
uses: microsoft/[email protected]

- name: Setup NuGet
uses: NuGet/[email protected]

- name: Restore dependencies
run: nuget restore NFive.SDK.Core.sln

- name: Build the solution
run: msbuild NFive.SDK.Core.sln /p:Configuration=Release /p:Outdir=Build

- uses: vimtor/action-zip@v1
with:
files: Build/
dest: ${{ env.ZipName }}

# Create a Release on the GitHub project
- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
with:
tag_name: ${{ env.SEMVER }}
release_name: ${{ env.SEMVER }}
draft: false
prerelease: false

# Upload the Build Artifact to the Release
- name: Update release asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: .\${{ env.ZipName }}
asset_name: ${{ env.ZipName }}
asset_content_type: application/zip
62 changes: 62 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: CI

on:
push:
branches:
- "**"
tags:
- "v*.*.*"
pull_request:
branches:
- "**"

jobs:
calculate-version:
name: Calculate Version
runs-on: ubuntu-latest
outputs:
semVer: ${{ steps.gitversion.outputs.semVer }}

steps:
- uses: actions/[email protected]
with:
fetch-depth: 0

- name: Install GitVersion
uses: gittools/actions/gitversion/[email protected]
with:
versionSpec: "5.x"

- name: Determine Version
id: gitversion
uses: gittools/actions/gitversion/[email protected]
with:
useConfigFile: true
configFilePath: ./.github/GitVersion.yml

build:
runs-on: windows-latest
needs: calculate-version
env:
SEMVER: ${{ needs.calculate-version.outputs.semVer }}

steps:
- uses: actions/[email protected]

- name: Setup MSBuild
uses: microsoft/[email protected]

- name: Setup NuGet
uses: NuGet/[email protected]

- name: Restore dependencies
run: nuget restore NFive.SDK.Core.sln

- name: Build the solution
run: msbuild NFive.SDK.Core.sln /p:Configuration=Release /p:Outdir=Build

- name: Attach Zip as build artifact
uses: actions/[email protected]
with:
name: NFive.SDK.Core-${{ env.SEMVER }}
path: Build
2 changes: 1 addition & 1 deletion Configuration/LocaleConfiguration.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using JetBrains.Annotations;
using System;
using System.Collections.Generic;
using System.Globalization;
using JetBrains.Annotations;

namespace NFive.SDK.Core.Configuration
{
Expand Down
2 changes: 1 addition & 1 deletion Configuration/SteamId.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using JetBrains.Annotations;
using System;

namespace NFive.SDK.Core.Configuration
{
Expand Down
7 changes: 1 addition & 6 deletions Controllers/ControllerConfiguration.cs
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
using System;
using JetBrains.Annotations;
using System;

namespace NFive.SDK.Core.Controllers
{
/// <inheritdoc />
/// <summary>
/// Represents the configuration that is automatically loaded into a <c>ConfigurableController</c>.
/// </summary>
/// <seealso cref="IControllerConfiguration" />
[PublicAPI]
[Serializable]
public abstract class ControllerConfiguration : IControllerConfiguration
Expand Down
2 changes: 1 addition & 1 deletion Diagnostics/ILogger.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using JetBrains.Annotations;
using System;

namespace NFive.SDK.Core.Diagnostics
{
Expand Down
2 changes: 1 addition & 1 deletion Extensions/NumericExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using JetBrains.Annotations;
using System;

namespace NFive.SDK.Core.Extensions
{
Expand Down
2 changes: 1 addition & 1 deletion Extensions/PositionExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using JetBrains.Annotations;
using NFive.SDK.Core.Models;
using System;

namespace NFive.SDK.Core.Extensions
{
Expand Down
2 changes: 1 addition & 1 deletion Extensions/StringExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using JetBrains.Annotations;
using System.Globalization;
using System.Linq;
using System.Text.RegularExpressions;
using JetBrains.Annotations;

namespace NFive.SDK.Core.Extensions
{
Expand Down
2 changes: 1 addition & 1 deletion Extensions/Vector2Extensions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using JetBrains.Annotations;
using NFive.SDK.Core.Models;
using System;

namespace NFive.SDK.Core.Extensions
{
Expand Down
2 changes: 1 addition & 1 deletion Extensions/Vector3Extensions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using JetBrains.Annotations;
using NFive.SDK.Core.Models;
using System;

namespace NFive.SDK.Core.Extensions
{
Expand Down
2 changes: 1 addition & 1 deletion Input/InputModifier.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using JetBrains.Annotations;
using System;

namespace NFive.SDK.Core.Input
{
Expand Down
5 changes: 1 addition & 4 deletions Locales/ILocaleCatalog.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
using System.Globalization;
using JetBrains.Annotations;
using System.Globalization;

namespace NFive.SDK.Core.Locales
{
/// <summary>
/// A GNU gettext locale catalog for a given culture.
/// </summary>
[PublicAPI]
public interface ILocaleCatalog
{
Expand Down
2 changes: 1 addition & 1 deletion Models/Color.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System.ComponentModel.DataAnnotations.Schema;
using JetBrains.Annotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace NFive.SDK.Core.Models
{
Expand Down
2 changes: 1 addition & 1 deletion Models/IIdentityModel.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using JetBrains.Annotations;
using System;

namespace NFive.SDK.Core.Models
{
Expand Down
4 changes: 2 additions & 2 deletions Models/IdentityModel.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using System.ComponentModel.DataAnnotations;
using JetBrains.Annotations;
using NFive.SDK.Core.Helpers;
using System;
using System.ComponentModel.DataAnnotations;

namespace NFive.SDK.Core.Models
{
Expand Down
4 changes: 2 additions & 2 deletions Models/Player/Session.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using JetBrains.Annotations;
using Newtonsoft.Json;
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using JetBrains.Annotations;
using Newtonsoft.Json;

namespace NFive.SDK.Core.Models.Player
{
Expand Down
2 changes: 1 addition & 1 deletion Models/Player/User.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using JetBrains.Annotations;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using JetBrains.Annotations;

namespace NFive.SDK.Core.Models.Player
{
Expand Down
2 changes: 1 addition & 1 deletion Models/Position.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using JetBrains.Annotations;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using JetBrains.Annotations;

namespace NFive.SDK.Core.Models
{
Expand Down
2 changes: 1 addition & 1 deletion Models/Vector3.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System.ComponentModel.DataAnnotations;
using JetBrains.Annotations;
using System.ComponentModel.DataAnnotations;

namespace NFive.SDK.Core.Models
{
Expand Down
Loading