Added initial build.
This commit is contained in:
parent
771da62400
commit
084d6e3544
|
|
@ -5,18 +5,14 @@
|
||||||
/TestResults
|
/TestResults
|
||||||
*.vspscc
|
*.vspscc
|
||||||
*.vssscc
|
*.vssscc
|
||||||
deploy
|
|
||||||
deploy/*
|
|
||||||
*.suo
|
*.suo
|
||||||
*.cache
|
*.cache
|
||||||
*.docstates
|
*.docstates
|
||||||
_ReSharper.*
|
|
||||||
*.csproj.user
|
*.csproj.user
|
||||||
*[Rr]e[Ss]harper.user
|
*[Rr]e[Ss]harper.user
|
||||||
_ReSharper.*/
|
_ReSharper.*/
|
||||||
packages/*
|
packages/*
|
||||||
artifacts/*
|
artifacts/*
|
||||||
msbuild.log
|
|
||||||
PublishProfiles/
|
PublishProfiles/
|
||||||
*.psess
|
*.psess
|
||||||
*.vsp
|
*.vsp
|
||||||
|
|
@ -24,11 +20,4 @@ PublishProfiles/
|
||||||
*.userprefs
|
*.userprefs
|
||||||
*DS_Store
|
*DS_Store
|
||||||
*.ncrunchsolution
|
*.ncrunchsolution
|
||||||
*.log
|
.nuget/NuGet.exe
|
||||||
*.vspx
|
|
||||||
*.log.txt
|
|
||||||
/tests/Microsoft.AspNet.SignalR.FunctionalTests/artifacts/
|
|
||||||
/samples/Microsoft.AspNet.SignalR.Client.WindowsStoreJavaScript.Samples/bld/
|
|
||||||
jquery.signalR.js
|
|
||||||
jquery.signalR.min.js
|
|
||||||
xamarin/SignalRPackage/component/lib/mobile/
|
|
||||||
|
|
@ -0,0 +1,12 @@
|
||||||
|
@echo off
|
||||||
|
cd %~dp0
|
||||||
|
|
||||||
|
IF EXIST .nuget\NuGet.exe goto part2
|
||||||
|
echo Downloading latest version of NuGet.exe...
|
||||||
|
mkdir .nuget
|
||||||
|
@powershell -NoProfile -ExecutionPolicy unrestricted -Command "((new-object net.webclient).DownloadFile('https://nuget.org/nuget.exe', '.nuget\NuGet.exe'))"
|
||||||
|
|
||||||
|
:part2
|
||||||
|
set EnableNuGetPackageRestore=true
|
||||||
|
.nuget\NuGet.exe install Sake -version 0.2 -o packages
|
||||||
|
packages\Sake.0.2\tools\Sake.exe -I build -f makefile.shade %*
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
@{/*
|
||||||
|
|
||||||
|
k-build
|
||||||
|
Builds project. Downloads and executes k sdk tools.
|
||||||
|
|
||||||
|
projectFile=''
|
||||||
|
Required. Path to the project.json to build.
|
||||||
|
|
||||||
|
*/}
|
||||||
|
|
||||||
|
var projectFolder='${Path.GetDirectoryName(projectFile)}'
|
||||||
|
var projectName='${Path.GetFileName(projectFolder)}'
|
||||||
|
var projectBin='${Path.Combine(projectFolder, "bin")}'
|
||||||
|
|
||||||
|
directory delete="${projectBin}"
|
||||||
|
k command='build ${projectFolder}'
|
||||||
|
copy sourceDir='${projectBin}' outputDir='${Path.Combine(BUILD_DIR, projectName)}'
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
@{/*
|
||||||
|
|
||||||
|
k-clean
|
||||||
|
Cleans project. Downloads and executes k sdk tools.
|
||||||
|
|
||||||
|
projectFile=''
|
||||||
|
Required. Path to the project.json to build.
|
||||||
|
|
||||||
|
*/}
|
||||||
|
|
||||||
|
var projectFolder='${Path.GetDirectoryName(projectFile)}'
|
||||||
|
|
||||||
|
k command='clean ${projectFolder}'
|
||||||
|
|
@ -0,0 +1,43 @@
|
||||||
|
use namespace="System"
|
||||||
|
use namespace="System.IO"
|
||||||
|
use import="Files"
|
||||||
|
|
||||||
|
default BASE_DIR='${Directory.GetCurrentDirectory()}'
|
||||||
|
default TARGET_DIR='${Path.Combine(BASE_DIR, "artifacts")}'
|
||||||
|
default BUILD_DIR='${Path.Combine(TARGET_DIR, "build")}'
|
||||||
|
default TEST_DIR='${Path.Combine(TARGET_DIR, "test")}'
|
||||||
|
|
||||||
|
@{
|
||||||
|
E("K_BUILD_VERSION", "t" + DateTime.UtcNow.ToString("yyMMddHHmmss"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#target-dir-clean target="clean"
|
||||||
|
directory delete="${TARGET_DIR}"
|
||||||
|
|
||||||
|
#build-clean target='clean'
|
||||||
|
k-clean each='var projectFile in Files.Include("src/**/project.json")'
|
||||||
|
|
||||||
|
#build-compile target='compile'
|
||||||
|
k-build each='var projectFile in Files.Include("src/**/project.json")'
|
||||||
|
@{
|
||||||
|
foreach (var nupkg in Files.Include(Path.Combine(BUILD_DIR, "*/*.nupkg")))
|
||||||
|
{
|
||||||
|
File.Copy(nupkg, Path.Combine(BUILD_DIR, Path.GetFileName(nupkg)), true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#nuget-install target='install' description='Copy NuGet packages to local repo'
|
||||||
|
@{
|
||||||
|
var HOME_DIR = E("HOME");
|
||||||
|
if (string.IsNullOrEmpty(HOME_DIR))
|
||||||
|
{
|
||||||
|
HOME_DIR = E("HOMEDRIVE") + E("HOMEPATH");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
copy sourceDir='${BUILD_DIR}' include='*.nupkg' outputDir='${Path.Combine(HOME_DIR, ".nuget")}' overwrite='${true}'
|
||||||
|
|
||||||
|
|
||||||
|
functions @{
|
||||||
|
string E(string key) { return Environment.GetEnvironmentVariable(key); }
|
||||||
|
void E(string key, string value) { Environment.SetEnvironmentVariable(key, value); }
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,31 @@
|
||||||
|
@{/*
|
||||||
|
|
||||||
|
k
|
||||||
|
Run klr commands in your project. Downloads and executes k sdk.
|
||||||
|
|
||||||
|
kVersion='0.0.1-pre-30109-087'
|
||||||
|
May be passed to override the nuget package version holding xunit console runner.
|
||||||
|
|
||||||
|
kProgram='...'
|
||||||
|
May be passed to override the path to the xunit program that will be executed
|
||||||
|
|
||||||
|
command=''
|
||||||
|
|
||||||
|
*/}
|
||||||
|
|
||||||
|
default kLatestSuccessful='\\wsr-teamcity\Drops\ProjectK.Main\latest-successful\sdk'
|
||||||
|
default kVersion=''
|
||||||
|
|
||||||
|
test if='string.IsNullOrEmpty(kVersion)'
|
||||||
|
for each='var file in System.IO.Directory.EnumerateFiles(kLatestSuccessful).Select(System.IO.Path.GetFileName)'
|
||||||
|
test if='file.StartsWith("ProjectK.") && file.EndsWith(".nupkg")'
|
||||||
|
- kVersion = file.Substring("ProjectK.".Length, file.Length - "ProjectK.".Length - ".nupkg".Length);
|
||||||
|
|
||||||
|
default kProgram='packages/ProjectK.${kVersion}/tools/k.cmd'
|
||||||
|
|
||||||
|
-// Download xunit from nuget sources if not already present
|
||||||
|
test if='!File.Exists(kProgram)'
|
||||||
|
log info='Installing ProjectK ${kVersion} from ${kLatestSuccessful}'
|
||||||
|
nuget-install package='ProjectK' packageVersion='${kVersion}' outputDir='packages' extra='-Source ${kLatestSuccessful}'
|
||||||
|
|
||||||
|
exec program='${Path.GetFullPath(kProgram)}' commandline='${command}'
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
|
||||||
|
var VERSION='0.1'
|
||||||
|
var FULL_VERSION='0.1'
|
||||||
|
var AUTHORS='Microsoft'
|
||||||
|
|
||||||
|
use-standard-lifecycle
|
||||||
|
k-standard-goals
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
{
|
{
|
||||||
"dependencies": [],
|
"configurations": {
|
||||||
"configurations": [
|
"net45": {},
|
||||||
{ "net45": {} },
|
"k10": {}
|
||||||
{ "k10": {} }
|
}
|
||||||
]
|
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue