diff --git a/.github/ci.yml b/.github/ci.yml new file mode 100644 index 0000000..415b338 --- /dev/null +++ b/.github/ci.yml @@ -0,0 +1,33 @@ +name: CI + +on: + push: + branches: + - master + - release-* + tags: + - '*.*.*' + pull_request: +jobs: + build: + strategy: + fail-fast: false + runs-on: windows-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Build and Test + run: ./Build.ps1 + shell: pwsh + - name: Push + env: + MYGET_MEDIATR_CI_API_KEY: ${{ secrets.MYGET_MEDIATR_CI_API_KEY }} + run: ./Push.ps1 + shell: pwsh + - name: Artifacts + uses: actions/upload-artifact@v2 + with: + name: artifacts + path: artifacts/**/* \ No newline at end of file diff --git a/Directory.Build.props b/Directory.Build.props index da4a861..b453d01 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -2,6 +2,9 @@ Jimmy Bogard latest - 8.0.0 + $(NoWarn);1701;1702;1591 + true + Apache-2.0 + v diff --git a/MediatR.DI.sln b/MediatR.DI.sln index 9b3343e..a84a5cd 100644 --- a/MediatR.DI.sln +++ b/MediatR.DI.sln @@ -5,9 +5,10 @@ VisualStudioVersion = 16.0.28803.156 MinimumVisualStudioVersion = 10.0.40219.1 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Build", "Build", "{1082ED20-13D1-444F-BAFD-17EFB9152981}" ProjectSection(SolutionItems) = preProject - appveyor.yml = appveyor.yml Build.ps1 = Build.ps1 + .github\ci.yml = .github\ci.yml Directory.Build.props = Directory.Build.props + Push.ps1 = Push.ps1 README.md = README.md EndProjectSection EndProject diff --git a/Push.ps1 b/Push.ps1 new file mode 100644 index 0000000..39e15c1 --- /dev/null +++ b/Push.ps1 @@ -0,0 +1,14 @@ +$scriptName = $MyInvocation.MyCommand.Name +$artifacts = "./artifacts" + +if ($Env:MYGET_MEDIATR_CI_API_KEY -eq $null) { + Write-Host "${scriptName}: MYGET_MEDIATR_CI_API_KEY is empty or not set. Skipped pushing package(s)." +} else { + Get-ChildItem $artifacts -Filter "*.nupkg" | ForEach-Object { + Write-Host "$($scriptName): Pushing $($_.Name)" + dotnet nuget push $_ --source https://www.myget.org/F/mediatr-ci/api/v3/index.json --api-key $Env:MYGET_MEDIATR_CI_API_KEY + if ($lastexitcode -ne 0) { + throw ("Exec: " + $errorMessage) + } + } +} diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 76794be..0000000 --- a/appveyor.yml +++ /dev/null @@ -1,40 +0,0 @@ -version: '{build}' -pull_requests: - do_not_increment_build_number: true -branches: - only: - - master -image: Visual Studio 2017 -## temporary until 2.1 sdk is installed -install: - - ps: $urlCurrent = "https://dotnetcli.blob.core.windows.net/dotnet/Sdk/2.1.300/dotnet-sdk-2.1.300-win-x64.zip" - - ps: $env:DOTNET_INSTALL_DIR = "$pwd\.dotnetsdk" - - ps: mkdir $env:DOTNET_INSTALL_DIR -Force | Out-Null - - ps: $tempFileCurrent = [System.IO.Path]::GetTempFileName() - - ps: (New-Object System.Net.WebClient).DownloadFile($urlCurrent, $tempFileCurrent) - - ps: Add-Type -AssemblyName System.IO.Compression.FileSystem; [System.IO.Compression.ZipFile]::ExtractToDirectory($tempFileCurrent, $env:DOTNET_INSTALL_DIR) - - ps: $env:Path = "$env:DOTNET_INSTALL_DIR;$env:Path" -nuget: - disable_publish_on_pr: true -build_script: -- ps: .\Build.ps1 -test: off -artifacts: -- path: .\artifacts\**\*.nupkg - name: NuGet -deploy: -- provider: NuGet - server: https://www.myget.org/F/mediatr-ci/api/v2/package - api_key: - secure: zKeQZmIv9PaozHQRJmrlRHN+jMCI64Uvzmb/vwePdXFR5CUNEHalnZdOCg0vrh8t - skip_symbols: true - on: - branch: master -- provider: NuGet - name: production - skip_symbols: true - api_key: - secure: t3blEIQiDIYjjWhOSTTtrcAnzJkmSi+0zYPxC1v4RDzm6oI/gIpD6ZtrOGsYu2jE - on: - branch: master - appveyor_repo_tag: true \ No newline at end of file diff --git a/assets/logo/flat_128x128.png b/assets/logo/flat_128x128.png new file mode 100644 index 0000000..821aa50 Binary files /dev/null and b/assets/logo/flat_128x128.png differ diff --git a/assets/logo/flat_32x32.png b/assets/logo/flat_32x32.png new file mode 100644 index 0000000..18ab4dd Binary files /dev/null and b/assets/logo/flat_32x32.png differ diff --git a/assets/logo/flat_64x64.png b/assets/logo/flat_64x64.png new file mode 100644 index 0000000..11bc343 Binary files /dev/null and b/assets/logo/flat_64x64.png differ diff --git a/assets/logo/gradient_128x128.png b/assets/logo/gradient_128x128.png new file mode 100644 index 0000000..82789c2 Binary files /dev/null and b/assets/logo/gradient_128x128.png differ diff --git a/assets/logo/gradient_32x32.png b/assets/logo/gradient_32x32.png new file mode 100644 index 0000000..ab5ff1d Binary files /dev/null and b/assets/logo/gradient_32x32.png differ diff --git a/assets/logo/gradient_64x64.png b/assets/logo/gradient_64x64.png new file mode 100644 index 0000000..5e3ae34 Binary files /dev/null and b/assets/logo/gradient_64x64.png differ diff --git a/src/MediatR.Extensions.Microsoft.DependencyInjection/MediatR.Extensions.Microsoft.DependencyInjection.csproj b/src/MediatR.Extensions.Microsoft.DependencyInjection/MediatR.Extensions.Microsoft.DependencyInjection.csproj index c7a5be0..deee737 100644 --- a/src/MediatR.Extensions.Microsoft.DependencyInjection/MediatR.Extensions.Microsoft.DependencyInjection.csproj +++ b/src/MediatR.Extensions.Microsoft.DependencyInjection/MediatR.Extensions.Microsoft.DependencyInjection.csproj @@ -9,19 +9,24 @@ mediator;request;response;queries;commands;notifications https://raw.githubusercontent.com/jbogard/MediatR/master/assets/logo/gradient_128x128.png https://github.com/jbogard/MediatR.Extensions.Microsoft.DependencyInjection - https://github.com/jbogard/MediatR/blob/master/LICENSE git git://github.com/jbogard/MediatR.Extensions.Microsoft.DependencyInjection - false - false - false true ..\..\MediatR.snk + gradient_128x128.png + + + + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + diff --git a/src/MediatR.Extensions.Microsoft.DependencyInjection/Properties/AssemblyInfo.cs b/src/MediatR.Extensions.Microsoft.DependencyInjection/Properties/AssemblyInfo.cs deleted file mode 100644 index 78e6e00..0000000 --- a/src/MediatR.Extensions.Microsoft.DependencyInjection/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("MediatR.Extensions.Microsoft.DependencyInjection")] -[assembly: AssemblyTrademark("")] - -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from -// COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] - -// The following GUID is for the ID of the typelib if this project is exposed to COM -[assembly: Guid("cd3bcc44-44c0-4a5a-9041-34b558a9fbf2")]