Skip to content

Commit

Permalink
Merge branch 'release/0.13.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
phillipsj committed Mar 5, 2018
2 parents 76df620 + aaba5e5 commit 3ae8470
Show file tree
Hide file tree
Showing 9 changed files with 51 additions and 16 deletions.
6 changes: 3 additions & 3 deletions nuspec/nuget/Cake.Squirrel.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
<tags>Cake Squirrel</tags>
</metadata>
<files>
<file src="Cake.Squirrel.dll" target="lib\net45" />
<file src="Cake.Squirrel.pdb" target="lib\net45" />
<file src="Cake.Squirrel.xml" target="lib\net45" />
<file src="Cake.Squirrel.dll" target="lib\net46" />
<file src="Cake.Squirrel.pdb" target="lib\net46" />
<file src="Cake.Squirrel.xml" target="lib\net46" />
</files>
</package>
8 changes: 4 additions & 4 deletions src/Cake.Squirrel.Tests/Cake.Squirrel.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Cake.Core, Version=0.22.2.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Cake.Core.0.22.2\lib\net46\Cake.Core.dll</HintPath>
<Reference Include="Cake.Core, Version=0.26.1.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Cake.Core.0.26.1\lib\net46\Cake.Core.dll</HintPath>
</Reference>
<Reference Include="Cake.Testing, Version=0.22.2.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Cake.Testing.0.22.2\lib\net46\Cake.Testing.dll</HintPath>
<Reference Include="Cake.Testing, Version=0.26.1.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Cake.Testing.0.26.1\lib\net46\Cake.Testing.dll</HintPath>
</Reference>
<Reference Include="NSubstitute, Version=2.0.3.0, Culture=neutral, PublicKeyToken=92dd2e9066daa5ca, processorArchitecture=MSIL">
<HintPath>..\packages\NSubstitute.2.0.3\lib\net45\NSubstitute.dll</HintPath>
Expand Down
14 changes: 14 additions & 0 deletions src/Cake.Squirrel.Tests/SquirrelRunnerTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,19 @@ public void Should_Add_NuGet_Package_To_Arguments() {
// Then
result.Args.ShouldEqual("--releasify \"Package.nupkg\"");
}

[Fact]
public void Should_Include_No_Delta_Flag_To_Arguments()
{
// Given
var fixture = new SquirrelRunnerFixture();

// When
fixture.Settings.NoDelta = true;
var result = fixture.Run();

// Then
result.Args.ShouldEqual("--releasify \"Package.nupkg\" --no-delta");
}
}
}
4 changes: 2 additions & 2 deletions src/Cake.Squirrel.Tests/packages.config
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Cake.Core" version="0.22.2" targetFramework="net46" />
<package id="Cake.Testing" version="0.22.2" targetFramework="net46" />
<package id="Cake.Core" version="0.26.1" targetFramework="net46" />
<package id="Cake.Testing" version="0.26.1" targetFramework="net46" />
<package id="Microsoft.NETCore.Platforms" version="1.0.1" targetFramework="net45" />
<package id="NETStandard.Library" version="1.6.0" targetFramework="net45" />
<package id="NSubstitute" version="2.0.3" targetFramework="net45" />
Expand Down
4 changes: 2 additions & 2 deletions src/Cake.Squirrel/Cake.Squirrel.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@
<DocumentationFile>bin\Release\Cake.Squirrel.XML</DocumentationFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="Cake.Core, Version=0.22.2.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Cake.Core.0.22.2\lib\net46\Cake.Core.dll</HintPath>
<Reference Include="Cake.Core, Version=0.26.1.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Cake.Core.0.26.1\lib\net46\Cake.Core.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
Expand Down
6 changes: 3 additions & 3 deletions src/Cake.Squirrel/SquirrelAliases.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public static class SquirrelAliases
///
/// Task("PackageNoSettings")
/// .Does(() => {
/// Squirrel(GetFile("Package.nupkg"));
/// Squirrel(File("Package.nupkg"));
/// });
/// </code>
/// </example>
Expand All @@ -46,7 +46,7 @@ public static void Squirrel(this ICakeContext context, FilePath nugetPackage) {
/// settings.NoMsi = true;
/// settings.Silent = true;
///
/// Squirrel(GetFile("Package.nupkg"), settings);
/// Squirrel(File("Package.nupkg"), settings);
/// });
/// </code>
/// </example>
Expand Down Expand Up @@ -78,7 +78,7 @@ public static void Squirrel(this ICakeContext context, FilePath nugetPackage, Sq
/// settings.NoMsi = true;
/// settings.Silent = true;
///
/// Squirrel(GetFile("Package.nupkg"), settings, true, false);
/// Squirrel(File("Package.nupkg"), settings, true, false);
/// });
/// </code>
/// </example>
Expand Down
7 changes: 6 additions & 1 deletion src/Cake.Squirrel/SquirrelRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,12 @@ private ProcessArgumentBuilder GetArguments(FilePath nugetPackage, SquirrelSetti
if (settings.NoMsi) {
builder.Append("--no-msi");
}

if (!string.IsNullOrWhiteSpace(settings.FrameworkVersion)) {
builder.Append("--framework-version {0}", settings.FrameworkVersion);
}
if (settings.NoDelta) {
builder.Append("--no-delta");
}
return builder;
}

Expand Down
16 changes: 16 additions & 0 deletions src/Cake.Squirrel/SquirrelSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,5 +90,21 @@ public SquirrelSettings() {}
/// <c>true</c> to not generate an MSI package; otherwise, <c>false</c>.
/// </value>
public bool NoMsi { get; set; }

/// <summary>
/// Gets or sets the required .NET framework version
/// </summary>
/// <value>
/// .NET framework version, e.g. net461
/// </value>
public string FrameworkVersion { get; set; }

/// <summary>
/// Gets or sets Don't generate delta packages to save time.
/// </summary>
/// <value>
/// <c>true</c> to not generate delta packages; otherwise, <c>false</c>.
/// </value>
public bool NoDelta { get; set; }
}
}
2 changes: 1 addition & 1 deletion src/Cake.Squirrel/packages.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Cake.Core" version="0.22.2" targetFramework="net46" />
<package id="Cake.Core" version="0.26.1" targetFramework="net46" />
</packages>

0 comments on commit 3ae8470

Please sign in to comment.