From ecbb52fa409b41ddad32aac8079df4420b3b7ae3 Mon Sep 17 00:00:00 2001 From: David Fowler Date: Mon, 17 Mar 2014 00:37:20 -0700 Subject: [PATCH] Updated to use KoreBuild - Updated solution file to use generated projects - Updated to use new test runner --- .gitattributes | 50 ++++++++++++++++ .gitignore | 39 +++++++------ NuGet.Config | 13 +++++ WebSockets.sln | 38 ++++++++----- build.cmd | 23 ++++++++ global.json | 3 + makefile.shade | 7 +++ .../Microsoft.Net.WebSockets.csproj | 57 ------------------- src/Microsoft.Net.WebSockets/project.json | 6 ++ .../Microsoft.Net.WebSockets.Test.csproj | 6 -- .../packages.config | 5 -- .../project.json | 20 +++++++ test/TestClient/App.config | 6 +- test/TestClient/TestClient.csproj | 9 +-- 14 files changed, 176 insertions(+), 106 deletions(-) create mode 100644 .gitattributes create mode 100644 NuGet.Config create mode 100644 build.cmd create mode 100644 global.json create mode 100644 makefile.shade delete mode 100644 src/Microsoft.Net.WebSockets/Microsoft.Net.WebSockets.csproj create mode 100644 src/Microsoft.Net.WebSockets/project.json delete mode 100644 test/Microsoft.Net.WebSockets.Test/packages.config create mode 100644 test/Microsoft.Net.WebSockets.Test/project.json diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000..bdaa5ba982 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,50 @@ +*.doc diff=astextplain +*.DOC diff=astextplain +*.docx diff=astextplain +*.DOCX diff=astextplain +*.dot diff=astextplain +*.DOT diff=astextplain +*.pdf diff=astextplain +*.PDF diff=astextplain +*.rtf diff=astextplain +*.RTF diff=astextplain + +*.jpg binary +*.png binary +*.gif binary + +*.cs text=auto diff=csharp +*.vb text=auto +*.resx text=auto +*.c text=auto +*.cpp text=auto +*.cxx text=auto +*.h text=auto +*.hxx text=auto +*.py text=auto +*.rb text=auto +*.java text=auto +*.html text=auto +*.htm text=auto +*.css text=auto +*.scss text=auto +*.sass text=auto +*.less text=auto +*.js text=auto +*.lisp text=auto +*.clj text=auto +*.sql text=auto +*.php text=auto +*.lua text=auto +*.m text=auto +*.asm text=auto +*.erl text=auto +*.fs text=auto +*.fsx text=auto +*.hs text=auto + +*.csproj text=auto +*.vbproj text=auto +*.fsproj text=auto +*.dbproj text=auto +*.sln text=auto eol=crlf diff --git a/.gitignore b/.gitignore index cb3474e72b..8bc217058d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,21 +1,24 @@ -bin -obj -*.suo +[Oo]bj/ +[Bb]in/ +TestResults/ +.nuget/ +_ReSharper.*/ +packages/ +artifacts/ +PublishProfiles/ *.user +*.suo +*.cache +*.docstates _ReSharper.* -*.DS_Store -*.userprefs -*.pidb -*.vspx +nuget.exe +*net45.csproj +*k10.csproj *.psess -TestResults/* -TestResult.xml -nugetkey -packages -target -artifacts -StyleCop.Cache -node_modules -*.snk -.nuget/NuGet.exe -docs/build +*.vsp +*.pidb +*.userprefs +*DS_Store +*.ncrunchsolution +*.*sdf +*.ipch \ No newline at end of file diff --git a/NuGet.Config b/NuGet.Config new file mode 100644 index 0000000000..a059188b09 --- /dev/null +++ b/NuGet.Config @@ -0,0 +1,13 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/WebSockets.sln b/WebSockets.sln index abcfa94b4f..c2f3292dcd 100644 --- a/WebSockets.sln +++ b/WebSockets.sln @@ -1,30 +1,28 @@  Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 2013 -VisualStudioVersion = 12.0.30203.2 +VisualStudioVersion = 12.0.30313.0 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Net.WebSockets", "src\Microsoft.Net.WebSockets\Microsoft.Net.WebSockets.csproj", "{6C1D09CA-F799-44AE-8EC8-9D19C76080C1}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Net.WebSockets.Test", "test\Microsoft.Net.WebSockets.Test\Microsoft.Net.WebSockets.Test.csproj", "{EF1FE910-6E0C-4DE8-8CC1-6118B726A59E}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TestClient", "test\TestClient\TestClient.csproj", "{22AB02E0-0346-4C4B-BBE7-C829A8D1C19E}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TestServer", "test\TestServer\TestServer.csproj", "{4E5F5FCC-172C-44D9-BEA0-39098A79CD0B}" EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{2C7947A5-9FBD-4267-97C1-2D726D7B3BAF}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "test", "test", "{C45106D0-76C8-4776-A140-F7DD83CA2958}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{9E55FC5B-FD9C-4266-AB24-F3AA649D7C8B}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Net.WebSockets.net45", "src\Microsoft.Net.WebSockets\Microsoft.Net.WebSockets.net45.csproj", "{B43D2069-9690-49B2-BA0C-9E8ACC32CB83}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Net.WebSockets.Test.net45", "test\Microsoft.Net.WebSockets.Test\Microsoft.Net.WebSockets.Test.net45.csproj", "{DA755E15-86B8-4E9C-A3B0-B2D95E3646B5}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {6C1D09CA-F799-44AE-8EC8-9D19C76080C1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {6C1D09CA-F799-44AE-8EC8-9D19C76080C1}.Debug|Any CPU.Build.0 = Debug|Any CPU - {6C1D09CA-F799-44AE-8EC8-9D19C76080C1}.Release|Any CPU.ActiveCfg = Release|Any CPU - {6C1D09CA-F799-44AE-8EC8-9D19C76080C1}.Release|Any CPU.Build.0 = Release|Any CPU - {EF1FE910-6E0C-4DE8-8CC1-6118B726A59E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {EF1FE910-6E0C-4DE8-8CC1-6118B726A59E}.Debug|Any CPU.Build.0 = Debug|Any CPU - {EF1FE910-6E0C-4DE8-8CC1-6118B726A59E}.Release|Any CPU.ActiveCfg = Release|Any CPU - {EF1FE910-6E0C-4DE8-8CC1-6118B726A59E}.Release|Any CPU.Build.0 = Release|Any CPU {22AB02E0-0346-4C4B-BBE7-C829A8D1C19E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {22AB02E0-0346-4C4B-BBE7-C829A8D1C19E}.Debug|Any CPU.Build.0 = Debug|Any CPU {22AB02E0-0346-4C4B-BBE7-C829A8D1C19E}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -33,8 +31,22 @@ Global {4E5F5FCC-172C-44D9-BEA0-39098A79CD0B}.Debug|Any CPU.Build.0 = Debug|Any CPU {4E5F5FCC-172C-44D9-BEA0-39098A79CD0B}.Release|Any CPU.ActiveCfg = Release|Any CPU {4E5F5FCC-172C-44D9-BEA0-39098A79CD0B}.Release|Any CPU.Build.0 = Release|Any CPU + {B43D2069-9690-49B2-BA0C-9E8ACC32CB83}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {B43D2069-9690-49B2-BA0C-9E8ACC32CB83}.Debug|Any CPU.Build.0 = Debug|Any CPU + {B43D2069-9690-49B2-BA0C-9E8ACC32CB83}.Release|Any CPU.ActiveCfg = Release|Any CPU + {B43D2069-9690-49B2-BA0C-9E8ACC32CB83}.Release|Any CPU.Build.0 = Release|Any CPU + {DA755E15-86B8-4E9C-A3B0-B2D95E3646B5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {DA755E15-86B8-4E9C-A3B0-B2D95E3646B5}.Debug|Any CPU.Build.0 = Debug|Any CPU + {DA755E15-86B8-4E9C-A3B0-B2D95E3646B5}.Release|Any CPU.ActiveCfg = Release|Any CPU + {DA755E15-86B8-4E9C-A3B0-B2D95E3646B5}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(NestedProjects) = preSolution + {22AB02E0-0346-4C4B-BBE7-C829A8D1C19E} = {9E55FC5B-FD9C-4266-AB24-F3AA649D7C8B} + {4E5F5FCC-172C-44D9-BEA0-39098A79CD0B} = {9E55FC5B-FD9C-4266-AB24-F3AA649D7C8B} + {B43D2069-9690-49B2-BA0C-9E8ACC32CB83} = {2C7947A5-9FBD-4267-97C1-2D726D7B3BAF} + {DA755E15-86B8-4E9C-A3B0-B2D95E3646B5} = {C45106D0-76C8-4776-A140-F7DD83CA2958} + EndGlobalSection EndGlobal diff --git a/build.cmd b/build.cmd new file mode 100644 index 0000000000..7045ee1f84 --- /dev/null +++ b/build.cmd @@ -0,0 +1,23 @@ +@echo off +cd %~dp0 + +SETLOCAL +SET CACHED_NUGET=%LocalAppData%\NuGet\NuGet.exe + +IF EXIST %CACHED_NUGET% goto copynuget +echo Downloading latest version of NuGet.exe... +IF NOT EXIST %LocalAppData%\NuGet md %LocalAppData%\NuGet +@powershell -NoProfile -ExecutionPolicy unrestricted -Command "$ProgressPreference = 'SilentlyContinue'; Invoke-WebRequest 'https://www.nuget.org/nuget.exe' -OutFile '%CACHED_NUGET%'" + +:copynuget +IF EXIST .nuget\nuget.exe goto restore +md .nuget +copy %CACHED_NUGET% .nuget\nuget.exe > nul + +:restore +IF EXIST packages\KoreBuild goto run +.nuget\NuGet.exe install KoreBuild -ExcludeVersion -o packages -nocache -pre +.nuget\NuGet.exe install Sake -version 0.2 -o packages -ExcludeVersion + +:run +packages\Sake\tools\Sake.exe -I packages\KoreBuild\build -f makefile.shade %* diff --git a/global.json b/global.json new file mode 100644 index 0000000000..840c36f6ad --- /dev/null +++ b/global.json @@ -0,0 +1,3 @@ +{ + "sources": ["src"] +} \ No newline at end of file diff --git a/makefile.shade b/makefile.shade new file mode 100644 index 0000000000..6357ea2841 --- /dev/null +++ b/makefile.shade @@ -0,0 +1,7 @@ + +var VERSION='0.1' +var FULL_VERSION='0.1' +var AUTHORS='Microsoft' + +use-standard-lifecycle +k-standard-goals diff --git a/src/Microsoft.Net.WebSockets/Microsoft.Net.WebSockets.csproj b/src/Microsoft.Net.WebSockets/Microsoft.Net.WebSockets.csproj deleted file mode 100644 index dec92dc375..0000000000 --- a/src/Microsoft.Net.WebSockets/Microsoft.Net.WebSockets.csproj +++ /dev/null @@ -1,57 +0,0 @@ - - - - - Debug - AnyCPU - {6C1D09CA-F799-44AE-8EC8-9D19C76080C1} - Library - Properties - Microsoft.Net.WebSockets - Microsoft.Net.WebSockets - v4.5 - 512 - - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/Microsoft.Net.WebSockets/project.json b/src/Microsoft.Net.WebSockets/project.json new file mode 100644 index 0000000000..80f3c5a063 --- /dev/null +++ b/src/Microsoft.Net.WebSockets/project.json @@ -0,0 +1,6 @@ +{ + "version": "0.1-alpha-*", + "configurations": { + "net45": { } + } +} \ No newline at end of file diff --git a/test/Microsoft.Net.WebSockets.Test/Microsoft.Net.WebSockets.Test.csproj b/test/Microsoft.Net.WebSockets.Test/Microsoft.Net.WebSockets.Test.csproj index 25f16b963c..70cae1a0ff 100644 --- a/test/Microsoft.Net.WebSockets.Test/Microsoft.Net.WebSockets.Test.csproj +++ b/test/Microsoft.Net.WebSockets.Test/Microsoft.Net.WebSockets.Test.csproj @@ -52,12 +52,6 @@ - - - {6c1d09ca-f799-44ae-8ec8-9d19c76080c1} - Microsoft.Net.WebSockets - - diff --git a/test/Microsoft.Net.WebSockets.Test/packages.config b/test/Microsoft.Net.WebSockets.Test/packages.config deleted file mode 100644 index 67a23e70da..0000000000 --- a/test/Microsoft.Net.WebSockets.Test/packages.config +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file diff --git a/test/Microsoft.Net.WebSockets.Test/project.json b/test/Microsoft.Net.WebSockets.Test/project.json new file mode 100644 index 0000000000..4ddcfd6ef3 --- /dev/null +++ b/test/Microsoft.Net.WebSockets.Test/project.json @@ -0,0 +1,20 @@ +{ + "dependencies": { + "Microsoft.Net.WebSockets": "", + "Xunit.KRunner": "0.1-alpha-*", + "xunit.abstractions": "2.0.0-aspnet-*", + "xunit.assert": "2.0.0-aspnet-*", + "xunit.core": "2.0.0-aspnet-*", + "xunit.execution": "2.0.0-aspnet-*" + }, + "configurations": { + "net45": { + "dependencies": { + "System.Runtime" : "" + } + } + }, + "commands": { + "test": "Xunit.KRunner" + } +} \ No newline at end of file diff --git a/test/TestClient/App.config b/test/TestClient/App.config index 8e15646352..d0feca6f79 100644 --- a/test/TestClient/App.config +++ b/test/TestClient/App.config @@ -1,6 +1,6 @@ - + - + - \ No newline at end of file + diff --git a/test/TestClient/TestClient.csproj b/test/TestClient/TestClient.csproj index 842f76c15d..fdd95f9be8 100644 --- a/test/TestClient/TestClient.csproj +++ b/test/TestClient/TestClient.csproj @@ -9,8 +9,9 @@ Properties TestClient TestClient - v4.5 + v4.5.1 512 + AnyCPU @@ -48,9 +49,9 @@ - - {6c1d09ca-f799-44ae-8ec8-9d19c76080c1} - Microsoft.Net.WebSockets + + {b43d2069-9690-49b2-ba0c-9e8acc32cb83} + Microsoft.Net.WebSockets.net45