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

Release/6.0.1 #7

Merged
merged 4 commits into from
Apr 12, 2023
Merged
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
35 changes: 17 additions & 18 deletions .github/workflows/publish-packages.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
name: CD


on:
push:
branches:
- release/**
pull_request:
branches:
- release/**

workflow_run:
workflows: ["CI"]
branches: [ master ]
types:
- completed

jobs:
build:

env:
BUILD_CONFIG: 'Release'
SOLUTION: './Solution/Modules.sln'
MESSAGE: ${{ github.event.head_commit.message }}

runs-on: windows-latest

Expand All @@ -25,34 +26,32 @@ jobs:

- name: Get Build Version
run: |
Import-Module .\Tools\GetBuildVersion.psm1
Write-Host $env:GITHUB_REF
$version = GetBuildVersion -VersionString $env:GITHUB_REF
echo "BUILD_VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf-8 -Append
Get-ChildItem
Import-Module .\Solution\Tools\GetBuildVersion.psm1
Write-Host $env:MESSAGE
$version = GetBuildVersion -VersionString $env:MESSAGE
echo "BUILD_VERSION=$version" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append
shell: pwsh

- name: Install .NET Core
uses: actions/setup-dotnet@v3
with:
dotnet-version: 5.0.x
dotnet-version: 6.0.x

- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1.0.2

- name: Setup NuGet
uses: NuGet/setup-nuget@v1.0.5

- name: Restore dependencies
run: nuget restore $env:SOLUTION

- name: Build
run: dotnet build $env:SOLUTION --configuration $env:BUILD_CONFIG -p:Version=$env:$BUILD_VERSION --no-restore
run: dotnet build $env:SOLUTION --configuration $env:BUILD_CONFIG /p:AssemblyVersion=$BUILD_VERSION --no-restore

- name: Run tests
run: dotnet test $env:SOLUTION /p:Configuration=$env:BUILD_CONFIG --no-restore --no-build --verbosity normal

- name: Publish
if: startsWith(github.ref, 'refs/heads/release')
run: |
nuget push **\*.nupkg -Source 'https://api.nuget.org/v3/index.json' -ApiKey ${{secrets.NUGET_API_KEY}}
nuget push **\*.nupkg -Source 'https://nuget.pkg.github.com/joshika39/index.json' --api-key ${{secrets.GIT_API_KEY}}
dotnet nuget push **\*.nupkg --source 'https://api.nuget.org/v3/index.json' --api-key ${{secrets.NUGET_API_KEY}}
dotnet nuget push **\*.nupkg --source 'https://nuget.pkg.github.com/joshika39/index.json' --api-key ${{secrets.GIT_API_KEY}}
3 changes: 0 additions & 3 deletions Solution/Implementation/Implementation.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,9 @@
<TargetFramework>net5.0</TargetFramework>
<PackageId>joshika39-$(AssemblyName)</PackageId>
<Title>Implementation</Title>
<Version>0.0.6</Version>
<Authors>Joshua Hegedus</Authors>
<Company>JHost</Company>
<Description>This is the backend for my base library.</Description>
<AssemblyVersion>0.0.6</AssemblyVersion>
<FileVersion>0.0.6</FileVersion>
<NeutralLanguage>en</NeutralLanguage>
</PropertyGroup>

Expand Down
3 changes: 0 additions & 3 deletions Solution/Infrastructure/Infrastructure.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,9 @@
<TargetFramework>net5.0</TargetFramework>
<PackageId>joshika39-$(AssemblyName)</PackageId>
<Title>Infrastructure</Title>
<Version>0.0.6</Version>
<Authors>Joshua Hegedus</Authors>
<Company>JHost</Company>
<Description>This contains the interfaces for my base library.</Description>
<AssemblyVersion>0.0.6</AssemblyVersion>
<FileVersion>0.0.6</FileVersion>
<NeutralLanguage>en</NeutralLanguage>
</PropertyGroup>

Expand Down