Browse Source

Updates flubu (#550)

master
Marko Zorec 4 years ago
committed by GitHub
parent
commit
62a34bb9db
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 10 additions and 12 deletions
  1. +1
    -1
      .travis.yml
  2. +1
    -1
      appveyor.yml
  3. +7
    -9
      build/BuildScript.cs
  4. +1
    -1
      build/BuildScript.csproj

+ 1
- 1
.travis.yml View File

@@ -12,5 +12,5 @@ services:


script: script:
- export PATH="$PATH:$HOME/.dotnet/tools" - export PATH="$PATH:$HOME/.dotnet/tools"
- dotnet tool install --global FlubuCore.GlobalTool --version 4.3.7
- dotnet tool install --global FlubuCore.GlobalTool --version 5.1.1
- flubu build tests - flubu build tests

+ 1
- 1
appveyor.yml View File

@@ -7,7 +7,7 @@ environment:
services: services:
- mysql - mysql
before_build: before_build:
- ps: dotnet tool install --global FlubuCore.GlobalTool --version 4.3.7
- ps: dotnet tool install --global FlubuCore.GlobalTool --version 5.1.1
build_script: build_script:
- ps: flubu - ps: flubu
test: off test: off


+ 7
- 9
build/BuildScript.cs View File

@@ -1,5 +1,6 @@
using System.Collections.Generic; using System.Collections.Generic;
using FlubuCore.Context; using FlubuCore.Context;
using FlubuCore.Context.Attributes.BuildProperties;
using FlubuCore.IO; using FlubuCore.IO;
using FlubuCore.Scripting; using FlubuCore.Scripting;
using FlubuCore.Scripting.Attributes; using FlubuCore.Scripting.Attributes;
@@ -9,23 +10,20 @@ namespace BuildScript
[Include("./build/BuildVersion.cs")] [Include("./build/BuildVersion.cs")]
public partial class BuildScript : DefaultBuildScript public partial class BuildScript : DefaultBuildScript
{ {
protected string ArtifactsDir => RootDirectory.CombineWith("artifacts");

[FromArg("c|configuration")] [FromArg("c|configuration")]
public string Configuration { get; set; }
[BuildConfiguration]
public string Configuration { get; set; } = "Release";

[SolutionFileName] public string SolutionFileName { get; set; } = "CAP.sln";


protected BuildVersion BuildVersion { get; set; } protected BuildVersion BuildVersion { get; set; }


protected string ArtifactsDir => RootDirectory.CombineWith("artifacts");
protected List<FileFullPath> ProjectFiles { get; set; } protected List<FileFullPath> ProjectFiles { get; set; }


protected List<FileFullPath> TestProjectFiles { get; set; } protected List<FileFullPath> TestProjectFiles { get; set; }


protected override void ConfigureBuildProperties(IBuildPropertiesContext context)
{
context.Properties.Set(BuildProps.SolutionFileName, "CAP.sln");
context.Properties.Set(BuildProps.BuildConfiguration, string.IsNullOrEmpty(Configuration) ? "Release" : Configuration);
}

protected override void BeforeBuildExecution(ITaskContext context) protected override void BeforeBuildExecution(ITaskContext context)
{ {
BuildVersion = FetchBuildVersion(context); BuildVersion = FetchBuildVersion(context);


+ 1
- 1
build/BuildScript.csproj View File

@@ -9,7 +9,7 @@
</ItemGroup> </ItemGroup>


<ItemGroup> <ItemGroup>
<PackageReference Include="FlubuCore" Version="4.3.7" />
<PackageReference Include="FlubuCore" Version="5.1.1" />
</ItemGroup> </ItemGroup>


</Project> </Project>

Loading…
Cancel
Save