Releases: cake-contrib/Cake.Npm
0.13.0-beta.1
0.12.1
0.12.0
- Updated to reference Cake.Core 0.22
- Removes support for net45
- updates doc xml to use net46 files
Requirements
- Cake 0.22.0 - Cake 0.25.0
If you are having trouble running your build with a pinned cake version (https://cakebuild.net/docs/tutorials/pinning-cake-version):
Downloading NuGet.exe...
Installing Cake...
Running build script...
Analyzing build script...
Processing build script...
Installing tools...
Installing addins...
Could not find any assemblies compatible with .NETFramework,Version=v4.5.
Error: Failed to install addin 'Cake.Npm'.
You will need to:
- Explicitly install Cake.Npm v0.11 or lower (https://cakebuild.net/docs/fundamentals/preprocessor-directives)
0.11.0
0.10.0
0.9.2
0.9.1
0.9.0
This release of Cake.Npm
comes with some significant breaking changes that alter how the addin is used within your build scripts. This release includes updates for the following issues and pull requests:
- #25 - Rewrite to have individual aliases for each command (#21, #22)
- #29 - Updates to Cake.Core 0.18
- #30 - Updates addin to use new msbuild15 project system and adds support for both
net45
,net46
and.netstandard1.6
- #11 - Adds missing log levels (
error
andhttp
) - #13 - Rewrite removes the
.WithLogLevel
implementation - #31 - typo correction in
readme.md
Requirements
- Cake 0.18.0 - Cake 0.21.1
How to migrate
Migrating to the new alias format should be very straight forward, however as the old aliases have been removed you will receive build script compile errors if your build script using the 0.8.0 syntax but downloads addins per build.
The more fluent syntax of previous versions has been removed in favour of a more standard settings object approach:
// 0.8.0
Npm.Install(settings => settings.Package("gulp"));
// 0.9.0
NpmInstall("gulp");
// 0.8.0
Npm.Install(settings => settings.Package("gulp").Globally());
// 0.9.0
var settings = new NpmInstallSettings();
settings.Global = true;
settings.AddPackage("gulp");
NpmInstall(settings);
// 0.8.0
Npm.FromPath("./my-path").Install();
// 0.9.0
var settings = new NpmInstallSettings();
settings.WorkingDirectory = "./my-path";
NpmInstall(settings);
For more examples see the current beta release branch here.
Sticking with 0.8.0
Firstly, I wouldnt recommend this, but if you want or need to then you can specify an addin version in your build script:
#addin nuget:?package=Cake.Npm&version=0.8.0
v0.9.0-beta.11 - Breaking changes
This release of Cake.Npm
comes with some significant breaking changes that alter how the addin is used within your build scripts. This release includes updates for the following issues and pull requests:
- #25 - Rewrite to have individual aliases for each command (#21, #22)
- #29 - Updates to Cake.Core 0.18
- #30 - Updates addin to use new msbuild15 project system and adds support for both
net45
,net46
and.netstandard1.6
- #11 - Adds missing log levels (
error
andhttp
) - #13 - Rewrite removes the
.WithLogLevel
implementation
Release timeline
As this is a major set of breaking changes the updates will not be simply released to nuget, instead this represents a beta release of the updated addin that will allow you to test and update your scripts. The timeline I have in mind for pushing a final stable version of 0.9.0 is currently estimated at 2 weeks. Meaning all being well the stable build of 0.9.0 will be pushed via nuget to all clean builds (without a tools/addins/Cake.Npm directory) sometime around the end of April.
I will look at coordinating some form of announcement with the cake team to ensure this information is disseminated as widely as possible.
How to test the beta
You can test your migration by altering your #addin
preprocessor directive to specify the prerelease option:
#addin nuget:?package=Cake.Npm&prerelease
Ensure you clear your /tools directory and re-run your build, you should get errors...now move onto the next section for migration information :)
How to migrate
Migrating to the new alias format should be very straight forward, however as the old aliases have been removed you will receive build script compile errors if your build script using the 0.8.0 syntax but downloads addins per build.
The more fluent syntax of previous versions has been removed in favour of a more standard settings object approach:
// 0.8.0
Npm.Install(settings => settings.Package("gulp"));
// 0.9.0
NpmInstall("gulp");
// 0.8.0
Npm.Install(settings => settings.Package("gulp").Globally());
// 0.9.0
var settings = new NpmInstallSettings();
settings.Global = true;
settings.AddPackage("gulp");
NpmInstall(settings);
For more examples see the current beta release branch here.
Sticking with 0.8.0
Firstly, I wouldnt recommend this, but if you want or need to then you can specify an addin version in your build script:
#addin nuget:?package=Cake.Npm&version=0.8.0