Use build globbing for tests and samples

This commit is contained in:
Pavel Krymets 2016-04-22 13:46:25 -07:00
Родитель 49de4edd8e
Коммит 2c0b3353a7
2 изменённых файлов: 3 добавлений и 7 удалений

Просмотреть файл

@ -15,9 +15,7 @@ default build_options=' ${E("KOREBUILD_DOTNET_BUILD_OPTIONS")}'
default framework = null default framework = null
@{ @{
var projectFolder=Path.GetDirectoryName(projectFile); var dotnetArgs=string.Format("build{0} {1} --configuration {2}", build_options, projectFile, configuration);
var dotnetArgs=string.Format("build{0} {1} --configuration {2}", build_options, projectFolder, configuration);
if (!string.IsNullOrEmpty(framework)) if (!string.IsNullOrEmpty(framework))
{ {

Просмотреть файл

@ -141,14 +141,12 @@ default PACKAGELIST_JSON_FILENAME = 'NuGetPackageVerifier.json'
#build-test target='compile' if='Directory.Exists("test") && !BuildSrcOnly' #build-test target='compile' if='Directory.Exists("test") && !BuildSrcOnly'
@{ @{
var projectFiles = Files.Include("test/*/project.json").ToList(); DotnetBuild("test/*/project.json", Configuration, BuildFramework);
projectFiles.ForEach(projectFile => DotnetBuild(projectFile, Configuration, BuildFramework));
} }
#build-samples target='compile' if='Directory.Exists("samples") && !BuildSrcOnly' #build-samples target='compile' if='Directory.Exists("samples") && !BuildSrcOnly'
@{ @{
var projectFiles = Files.Include("samples/*/project.json").ToList(); DotnetBuild("samples/*/project.json", Configuration, BuildFramework);
projectFiles.ForEach(projectFile => DotnetBuild(projectFile, Configuration, BuildFramework));
} }
#native-compile target='compile' if='!IsLinux && Directory.Exists(Path.Combine(BASE_DIR, "src"))' #native-compile target='compile' if='!IsLinux && Directory.Exists(Path.Combine(BASE_DIR, "src"))'