Skip to content

Commit

Permalink
ThreeMammals#20 - Tidy up. Update command line scripts. Fix running b…
Browse files Browse the repository at this point in the history
…enchmarks.
  • Loading branch information
binarymash committed Jan 29, 2017
1 parent e4a22e5 commit 3385406
Show file tree
Hide file tree
Showing 14 changed files with 37 additions and 74 deletions.
10 changes: 4 additions & 6 deletions Ocelot.sln
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,19 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
ProjectSection(SolutionItems) = preProject
.gitignore = .gitignore
appveyor.yml = appveyor.yml
build-and-run-tests.bat = build-and-run-tests.bat
build.bat = build.bat
build-and-run-tests.ps1 = build-and-run-tests.ps1
build.cake = build.cake
build.ps1 = build.ps1
configuration-explanation.txt = configuration-explanation.txt
global.json = global.json
LICENSE.md = LICENSE.md
Ocelot.nuspec = Ocelot.nuspec
push-to-nuget.bat = push-to-nuget.bat
README.md = README.md
release.ps1 = release.ps1
run-acceptance-tests.bat = run-acceptance-tests.bat
run-acceptance-tests.ps1 = run-acceptance-tests.ps1
run-benchmarks.bat = run-benchmarks.bat
run-tests.bat = run-tests.bat
run-unit-tests.bat = run-unit-tests.bat
run-benchmarks.ps1 = run-benchmarks.ps1
run-unit-tests.ps1 = run-unit-tests.ps1
EndProjectSection
EndProject
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Ocelot", "src\Ocelot\Ocelot.xproj", "{D6DF4206-0DBA-41D8-884D-C3E08290FDBB}"
Expand Down
1 change: 1 addition & 0 deletions build-and-release-unstable.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
./build.ps1 -target build-full
2 changes: 0 additions & 2 deletions build-and-run-tests.bat

This file was deleted.

1 change: 1 addition & 0 deletions build-and-run-tests.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
./build.ps1 -target RunTests
8 changes: 0 additions & 8 deletions build.bat

This file was deleted.

52 changes: 28 additions & 24 deletions build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,15 @@
#tool "nuget:?package=OpenCover"
#tool "nuget:?package=ReportGenerator"
#tool "nuget:?package=GitReleaseNotes"
#addin nuget:?package=Cake.DoInDirectory
#addin "Cake.Json"
#addin "nuget:?package=Cake.DoInDirectory"
#addin "nuget:?package=Cake.Json"

var target = Argument("target", "Default");
var artifactsDir = Directory("artifacts");

Information("target is " +target);

// versioning
var committedVersion = "0.0.0-dev";
var buildVersion = committedVersion;

//compile
// compile
var compileConfig = Argument("configuration", "Release");
Information("Build configuration is " + compileConfig);
var projectJson = "./src/Ocelot/project.json";

// build artifacts
var artifactsDir = Directory("artifacts");

// unit testing
var artifactsForUnitTestsDir = artifactsDir + Directory("UnitTests");
Expand All @@ -31,32 +25,42 @@ var artifactsForBenchmarkTestsDir = artifactsDir + Directory("BenchmarkTests");
var benchmarkTestAssemblies = @"./test/Ocelot.Benchmarks";

// packaging
var projectJson = "./src/Ocelot/project.json";
var packagesDir = artifactsDir + Directory("Packages");
var releaseNotesFile = packagesDir + File("releasenotes.md");
var artifactsFile = packagesDir + File("artifacts.txt");

//unstable releases
var publishUnstableBuilds = true;
// unstable releases
var nugetFeedUnstableKey = EnvironmentVariable("nuget-apikey-unstable");
var nugetFeedUnstableUploadUrl = "https://www.myget.org/F/ocelot-unstable/api/v2/package";
var nugetFeedUnstableSymbolsUploadUrl = "https://www.myget.org/F/ocelot-unstable/symbols/api/v2/package";

//stable releases
// stable releases
var tagsUrl = "https://api.github.com/repos/binarymash/ocelot/releases/tags/";
var releaseTag = "";
var nugetFeedStableKey = EnvironmentVariable("nuget-apikey-stable");
var nugetFeedStableUploadUrl = "https://www.myget.org/F/ocelot-stable/api/v2/package";
var nugetFeedStableSymbolsUploadUrl = "https://www.myget.org/F/ocelot-stable/symbols/api/v2/package";

// internal build variables - don't change these.
var releaseTag = "";
var buildVersion = committedVersion;
var committedVersion = "0.0.0-dev";

var target = Argument("target", "Default");

Information("target is " +target);
Information("Build configuration is " + compileConfig);

Task("Default")
.IsDependentOn("Build");

Task("Build")
.IsDependentOn("RunTests")
.IsDependentOn("CreatePackages")
.IsDependentOn("ReleasePackagesToUnstableFeed")
.Does(() =>
{
});
.IsDependentOn("CreatePackages");

Task("BuildAndReleaseUnstable")
.IsDependentOn("Build")
.IsDependentOn("ReleasePackagesToUnstableFeed");

Task("Clean")
.Does(() =>
{
Expand Down Expand Up @@ -138,7 +142,7 @@ Task("RunBenchmarkTests")

DoInDirectory(benchmarkTestAssemblies, () =>
{
DotNetCoreRun(".", "--args", buildSettings);
DotNetCoreRun(".", "", buildSettings);
});
});

Expand Down
8 changes: 0 additions & 8 deletions run-acceptance-tests.bat

This file was deleted.

1 change: 1 addition & 0 deletions run-acceptance-tests.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
./build -target RunAcceptanceTests
15 changes: 0 additions & 15 deletions run-benchmarks.bat

This file was deleted.

1 change: 1 addition & 0 deletions run-benchmarks.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
./build.ps1 -target RunBenchmarkTests
2 changes: 0 additions & 2 deletions run-tests.bat

This file was deleted.

8 changes: 0 additions & 8 deletions run-unit-tests.bat

This file was deleted.

1 change: 1 addition & 0 deletions run-unit-tests.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
./build.ps1 -target RunUnitTests
1 change: 0 additions & 1 deletion test.txt

This file was deleted.

0 comments on commit 3385406

Please sign in to comment.