From 23e42144104d8630639cc19e1e00db0e7aeb7bf6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miha=20Marki=C4=8D?= Date: Thu, 8 Feb 2024 11:34:49 +0100 Subject: [PATCH] (GH-10) Updates build script --- .appveyor.yml | 21 +++++++++++++++++++-- .config/dotnet-tools.json | 2 +- README.md | 22 ++++++++++++++++++++-- recipe.cake | 10 +++++----- 4 files changed, 45 insertions(+), 10 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index cda557f..4094b45 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -1,7 +1,24 @@ #---------------------------------# # Build Image # #---------------------------------# -image: Visual Studio 2019 +image: Visual Studio 2022 + +#---------------------------------# +# Install .NET # +#---------------------------------# +install: + - ps: $env:DOTNET_INSTALL_DIR = "$pwd\.dotnetsdk" + - ps: mkdir $env:DOTNET_INSTALL_DIR -Force | Out-Null + - ps: Invoke-WebRequest -Uri "https://dotnet.microsoft.com/download/dotnet/scripts/v1/dotnet-install.ps1" -OutFile "$($env:DOTNET_INSTALL_DIR)/dotnet-install.ps1" + # Required for Wyam + - ps: '& "$($env:DOTNET_INSTALL_DIR)/dotnet-install.ps1" -Version 2.1.818 -InstallDir $env:DOTNET_INSTALL_DIR' + # Required for GitVersion + - ps: '& "$($env:DOTNET_INSTALL_DIR)/dotnet-install.ps1" -Version 5.0.408 -InstallDir $env:DOTNET_INSTALL_DIR' + - ps: '& "$($env:DOTNET_INSTALL_DIR)/dotnet-install.ps1" -Version 6.0.411 -InstallDir $env:DOTNET_INSTALL_DIR' + - ps: '& "$($env:DOTNET_INSTALL_DIR)/dotnet-install.ps1" -Version 7.0.305 -InstallDir $env:DOTNET_INSTALL_DIR' + - ps: '& "$($env:DOTNET_INSTALL_DIR)/dotnet-install.ps1" -Version 8.0.101 -InstallDir $env:DOTNET_INSTALL_DIR' + - ps: $env:Path = "$env:DOTNET_INSTALL_DIR;$env:Path" + - ps: dotnet --info #---------------------------------# # Build Script # @@ -40,7 +57,7 @@ branches: # Build Cache # #---------------------------------# cache: -- tools -> recipe.cake +- "tools -> recipe.cake" #---------------------------------# # Skip builds for doc changes # diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index 727dfd7..4903ba5 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -3,7 +3,7 @@ "isRoot": true, "tools": { "cake.tool": { - "version": "0.38.5", + "version": "1.3.0", "commands": [ "dotnet-cake" ] diff --git a/README.md b/README.md index 83e4d1a..e84b8a6 100644 --- a/README.md +++ b/README.md @@ -4,10 +4,20 @@ A Cake AddIn that extends Cake with [ResourceHacker](http://angusj.com/resourceh [![cakebuild.net](https://img.shields.io/badge/WWW-cakebuild.net-blue.svg)](http://cakebuild.net/) [![NuGet](https://img.shields.io/nuget/v/Cake.ResourceHacker.svg)](https://www.nuget.org/packages/Cake.ResourceHacker) -[![Build status](https://ci.appveyor.com/api/projects/status/vi07dth3d1gek7ak?svg=true)](https://ci.appveyor.com/project/cakecontrib/cake-resourcehacker) + +|Branch|Status| +|------|------| +|Master|[![Build status](https://ci.appveyor.com/api/projects/status/github/cake-contrib/Cake.ResourceHacker?branch=master&svg=true)](https://ci.appveyor.com/project/cakecontrib/cake-resourcehacker)| +|Develop|[![Build status](https://ci.appveyor.com/api/projects/status/github/cake-contrib/Cake.ResourceHacker?branch=develop&svg=true)](https://ci.appveyor.com/project/cakecontrib/cake-resourcehacker)| + ## Important +1.3.0 +* References Cake 4.0.0 +* Drops support for .NET Framework +* Supports .net 6+ + 1.1.0 Supports Cake 0.33 1.0.0 Supports Cake 0.30 and .NET Standard 2.0. @@ -39,6 +49,14 @@ Other commands follow same convention. This version is built against ResourceHacker 5.1.6. +## Discussion + +If you have questions, search for an existing one, or create a new discussion on the Cake GitHub repository, using the `extension-q-a` category. + +[![Join in the discussion on the Cake repository](https://img.shields.io/badge/GitHub-Discussions-green?logo=github)](https://github.com/cake-build/cake/discussions/categories/extension-q-a) + ## Credits -Brought to you by [Miha Markic](https://github.com/MihaMarkic) ([@MihaMarkic](https://twitter.com/MihaMarkic/)) and contributors. \ No newline at end of file +Brought to you by [Miha Markic](https://github.com/MihaMarkic) and contributors. + +![Mastodon Follow](hts://github.com/MihaMarkic) ([@MihaMarkic](https://twitter.com/MihaMarkic/)) and contributors. \ No newline at end of file diff --git a/recipe.cake b/recipe.cake index b7b1ea5..da73b6f 100644 --- a/recipe.cake +++ b/recipe.cake @@ -1,25 +1,25 @@ -#load nuget:?package=Cake.Recipe&version=2.2.0 +#load nuget:?package=Cake.Recipe&version=3.1.1 Environment.SetVariableNames(); BuildParameters.SetParameters( - context: Context, + context: Context, buildSystem: BuildSystem, sourceDirectoryPath: "./src", title: "Cake.ResourceHacker", repositoryOwner: "cake-contrib", repositoryName: "Cake.ResourceHacker", appVeyorAccountName: "cakecontrib", - shouldRunDupFinder: false, + shouldPostToGitter: false, shouldRunInspectCode: false, shouldRunCodecov: false, - shouldRunDotNetCorePack: true); + shouldRunDotNetCorePack: true, + shouldRunCoveralls: false); // Disabled because it's currently failing BuildParameters.PrintParameters(Context); ToolSettings.SetToolSettings( context: Context, - dupFinderExcludePattern: new string[] { BuildParameters.RootDirectoryPath + "/src/Cake.ResourceHacker.Tests/*.cs" }, testCoverageFilter: "+[*]* -[nunit.*]* -[Cake.Core]* -[Cake.Testing]* -[*.Tests]*", testCoverageExcludeByAttribute: "*.ExcludeFromCodeCoverage*", testCoverageExcludeByFile: "*/*Designer.cs;*/*.g.cs;*/*.g.i.cs");