-
-
Notifications
You must be signed in to change notification settings - Fork 379
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #386 from shouldly/netcore
Switch to dotnet cli RC2 Preview 1 Tooling
- Loading branch information
Showing
473 changed files
with
1,115 additions
and
4,761 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
|
||
<configuration> | ||
<packageSources> | ||
<!-- add key="CoreCLR Xunit" value="https://www.myget.org/F/coreclr-xunit/api/v3/index.json" / --> | ||
<!-- add key="AspNet CI Feed" value="https://www.myget.org/F/aspnetcirelease/api/v3/index.json" /> --> | ||
<add key="myget.org xunit" value="https://www.myget.org/F/xunit/api/v3/index.json" /> | ||
<add key="api.nuget.org" value="https://api.nuget.org/v3/index.json" /> | ||
</packageSources> | ||
</configuration> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
assembly_info: | ||
patch: false | ||
|
||
platform: | ||
- Any CPU | ||
|
||
configuration: | ||
- Debug | ||
|
||
build_script: | ||
- ps: ./deploy.ps1 | ||
|
||
test: off | ||
skip_non_tags: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
#tool "nuget:?package=GitReleaseNotes" | ||
|
||
var target = Argument("target", "Default"); | ||
var shouldlyProj = "./src/Shouldly/project.json"; | ||
var outputDir = "./artifacts/"; | ||
|
||
Task("Clean") | ||
.Does(() => { | ||
if (DirectoryExists(outputDir)) | ||
{ | ||
DeleteDirectory(outputDir, recursive:true); | ||
} | ||
}); | ||
|
||
Task("Restore") | ||
.Does(() => { | ||
NuGetRestore("./src/Shouldly.sln"); | ||
}); | ||
|
||
GitVersion versionInfo = null; | ||
Task("Version") | ||
.Does(() => { | ||
GitVersion(new GitVersionSettings{ | ||
UpdateAssemblyInfo = true, | ||
OutputType = GitVersionOutput.BuildServer | ||
}); | ||
versionInfo = GitVersion(new GitVersionSettings{ OutputType = GitVersionOutput.Json }); | ||
// Update project.json | ||
var updatedProjectJson = System.IO.File.ReadAllText(shouldlyProj) | ||
.Replace("1.0.0-*", versionInfo.NuGetVersion); | ||
System.IO.File.WriteAllText(shouldlyProj, updatedProjectJson); | ||
}); | ||
|
||
Task("Build") | ||
.IsDependentOn("Clean") | ||
.IsDependentOn("Version") | ||
.IsDependentOn("Restore") | ||
.Does(() => { | ||
MSBuild("./src/Shouldly.sln"); | ||
}); | ||
|
||
Task("Test") | ||
.IsDependentOn("Build") | ||
.Does(() => { | ||
DotNetCoreTest("./src/Shouldly.Tests"); | ||
}); | ||
|
||
Task("Package") | ||
.IsDependentOn("Test") | ||
.Does(() => { | ||
var settings = new DotNetCorePackSettings | ||
{ | ||
OutputDirectory = outputDir, | ||
NoBuild = true | ||
}; | ||
DotNetCorePack(shouldlyProj, settings); | ||
// TODO not sure why this isn't working | ||
// GitReleaseNotes("outputDir/releasenotes.md", new GitReleaseNotesSettings { | ||
// WorkingDirectory = ".", | ||
// AllTags = false | ||
// }); | ||
var releaseNotesExitCode = StartProcess( | ||
@"tools\GitReleaseNotes\tools\gitreleasenotes.exe", | ||
new ProcessSettings { Arguments = ". /o artifacts/releasenotes.md" }); | ||
if (releaseNotesExitCode != 0) throw new Exception("Failed to generate release notes"); | ||
System.IO.File.WriteAllLines(outputDir + ".artifacts", new[]{ | ||
"nuget:Shouldly." + versionInfo.NuGetVersion + ".nupkg", | ||
"nugetSymbols:Shouldly." + versionInfo.NuGetVersion + ".symbols.nupkg", | ||
"releaseNotes:releasenotes.md" | ||
}); | ||
if (AppVeyor.IsRunningOnAppVeyor) | ||
{ | ||
foreach (var file in GetFiles(outputDir + "**/*")) | ||
AppVeyor.UploadArtifact(file.FullPath); | ||
} | ||
}); | ||
|
||
Task("Default") | ||
.IsDependentOn("Package"); | ||
|
||
RunTarget(target); |
Oops, something went wrong.