REM work in progress
REM Setup a non-production BigFix Eval Server with SQL Developer Edition.

REM http://software.bigfix.com/download/bes/95/BigFix-BES-9.5.9.62.exe
REM http://download.microsoft.com/download/2/5/0/2508F7B4-6DDE-4C3E-B1FA-E1EB66F2F79F/SQLServer2016-SSEI-Dev.exe

SET BASEFOLDER=C:\tmp

REM Make folder if not existing:  https://stackoverflow.com/questions/4165387/create-folder-with-batch-but-only-if-it-doesnt-already-exist
if not exist "%BASEFOLDER%" mkdir %BASEFOLDER%

REM Open folder:
start "" %BASEFOLDER%

REM https://github.com/jgstew/bigfix-content/blob/master/fixlet/Install%20SQL%20Server%20Management%20Studio%2016.5.1%20-%20Windows.bes
REM Download SQL Server Management Studio:
start "" powershell -command "& { (New-Object Net.WebClient).DownloadFile('https://download.microsoft.com/download/f/e/b/feb0e6be-21ce-4f98-abee-d74065e32d0a/SSMS-Setup-ENU.exe', '%BASEFOLDER%\SSMS-Setup-ENU.exe') }" -ExecutionPolicy Bypass

REM Download BigFix Root Server:
start "" powershell -command "& { (New-Object Net.WebClient).DownloadFile('http://software.bigfix.com/download/bes/100/BigFix-BES-Server-10.0.0.133.exe', '%BASEFOLDER%\BigFix-BES.exe') }" -ExecutionPolicy Bypass

REM Download BigFix Fixlet Debugger:
REM http://software.bigfix.com/download/bes/100/util/QNA10.0.0.133.zip
start "" powershell -command "& { (New-Object Net.WebClient).DownloadFile('http://software.bigfix.com/download/bes/100/util/QNA10.0.0.133.zip', '%BASEFOLDER%\BigFix-FixletDebugger.zip') }" -ExecutionPolicy Bypass

REM Download SQLServer Developer Edition:
powershell -command "& { (New-Object Net.WebClient).DownloadFile('https://download.microsoft.com/download/5/A/7/5A7065A2-C81C-4A31-9972-8A31AC9388C1/SQLServer2017-SSEI-Dev.exe', '%BASEFOLDER%\SQLServer-SSEI-Dev.exe') }" -ExecutionPolicy Bypass
REM Install SQLServer Developer Edition:
REM https://docs.microsoft.com/en-us/sql/database-engine/install-windows/install-sql-server-from-the-command-prompt?view=sql-server-2017
REM Download Commnad:
%BASEFOLDER%\SQLServer-SSEI-Dev.exe /MEDIAPATH="%BASEFOLDER%" /ACTION=Download /LANGUAGE=en-US /MEDIATYPE=CAB /QUIET

REM Install Command: (interactive)
%BASEFOLDER%\SQLServer-SSEI-Dev.exe /ACTION=Install /MEDIAPATH=C:\tmp /IACCEPTSQLSERVERLICENSETERMS /LANGUAGE=en-US

REM https://download.microsoft.com/download/0/5/B/05B2AF8F-906F-4C57-A58E-5780F64F9D62/SSMS-Setup-ENU.exe
REM Install SQL Server Management Studio:
%BASEFOLDER%\SSMS-Setup-ENU.exe /install /quiet /norestart

REM for some reason, this didn't create a start menu shortcut it seems for SQL Server Management Studio

REM press any key to continue....
pause

REM work in progress
REM Setup a non-production BigFix Eval Server with SQL Developer Edition.

REM http://software.bigfix.com/download/bes/95/BigFix-BES-9.5.9.62.exe
REM http://download.microsoft.com/download/2/5/0/2508F7B4-6DDE-4C3E-B1FA-E1EB66F2F79F/SQLServer2016-SSEI-Dev.exe

SET BASEFOLDER=C:\tmp

REM Make folder if not existing:  https://stackoverflow.com/questions/4165387/create-folder-with-batch-but-only-if-it-doesnt-already-exist
if not exist "%BASEFOLDER%" mkdir %BASEFOLDER%

REM Open folder:
start "" %BASEFOLDER%

REM https://github.com/jgstew/bigfix-content/blob/master/fixlet/Install%20SQL%20Server%20Management%20Studio%2016.5.1%20-%20Windows.bes
REM Download SQL Server Management Studio:
start "" powershell -command "& { (New-Object Net.WebClient).DownloadFile('https://download.microsoft.com/download/f/e/b/feb0e6be-21ce-4f98-abee-d74065e32d0a/SSMS-Setup-ENU.exe', '%BASEFOLDER%\SSMS-Setup-ENU.exe') }" -ExecutionPolicy Bypass

REM Download BigFix Root Server:
start "" powershell -command "& { (New-Object Net.WebClient).DownloadFile('http://software.bigfix.com/download/bes/100/BigFix-BES-10.0.0.133.exe', '%BASEFOLDER%\BigFix-BES.exe') }" -ExecutionPolicy Bypass

REM Download BigFix Fixlet Debugger:
REM http://software.bigfix.com/download/bes/100/util/QNA10.0.0.133.zip
start "" powershell -command "& { (New-Object Net.WebClient).DownloadFile('http://software.bigfix.com/download/bes/100/util/QNA10.0.0.133.zip', '%BASEFOLDER%\BigFix-FixletDebugger.zip') }" -ExecutionPolicy Bypass

REM Download SQLServer Developer Edition:
powershell -command "& { (New-Object Net.WebClient).DownloadFile('https://download.microsoft.com/download/5/A/7/5A7065A2-C81C-4A31-9972-8A31AC9388C1/SQLServer2017-SSEI-Dev.exe', '%BASEFOLDER%\SQLServer-SSEI-Dev.exe') }" -ExecutionPolicy Bypass
REM Install SQLServer Developer Edition:
REM https://docs.microsoft.com/en-us/sql/database-engine/install-windows/install-sql-server-from-the-command-prompt?view=sql-server-2017
REM Download Commnad:
%BASEFOLDER%\SQLServer-SSEI-Dev.exe /MEDIAPATH="%BASEFOLDER%" /ACTION=Download /LANGUAGE=en-US /MEDIATYPE=CAB /QUIET

REM Install Command: (interactive)
%BASEFOLDER%\SQLServer-SSEI-Dev.exe /ACTION=Install /MEDIAPATH=C:\tmp /IACCEPTSQLSERVERLICENSETERMS /LANGUAGE=en-US

REM https://download.microsoft.com/download/0/5/B/05B2AF8F-906F-4C57-A58E-5780F64F9D62/SSMS-Setup-ENU.exe
REM Install SQL Server Management Studio:
%BASEFOLDER%\SSMS-Setup-ENU.exe /install /quiet /norestart

REM for some reason, this didn't create a start menu shortcut it seems for SQL Server Management Studio

REM press any key to continue....
pause

Update bigfix_setup_root_eval.bat

Update bigfix_setup_root_eval.bat

switch to install generator URL instead of direct server download


@"%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe" -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin"
choco install googlechrome 7zip notepadplusplus.install firefox git.install putty winscp.install azurestorageexplorer tortoisegit vagrant chefdk puppet-agent packer terraform virtualbox visualstudiocode vmwareworkstation -y
refreshenv
vagrant plugin install vagrant-winrm
vagrant plugin install vagrant-omnibus
vagrant plugin install vagrant-berkshelf
vagrant box add mwrock/Windows2016 --provider virtualbox
code --install-extension ms-vscode.powershell
code --install-extension msazurermtools.azurerm-vscode-tools
code --install-extension HookyQR.beautify
code --install-extension Pendrica.chef
code --install-extension ms-vscode.PeterJausovec.vscode-docker
code --install-extension alefragnani.project-manager
code --install-extension Borke.puppet
code --install-extension mauve.terraform
code --install-extension Pendrica.chef
code --install-extension bbenoist.vagrant
code --install-extension burtlo.inspec
code --install-extension ms-mssql.mssql
code --list-extensions

#Install Azure Powershell Cmdlets
downloadFile https://github.com/Azure/azure-powershell/releases/download/v4.2.1-July2017/azure-powershell.4.2.1.msi c:\windows\temp\
Start-Process c:\windows\temp\azure-powershell.4.2.1.msi -ArgumentList "/quiet /qn /norestart" -wait

#Pull this github repo as may be useful things i refer to later
mkdir c:\github
cd c:\github
git clone https://github.com/iaingblack/Automation.git

#This breaks the above commands by changing shell (I think) so do it last
chef gem install kitchen-all

#Add if required
vagrant box add mwrock/Windows2012R2 --provider virtualbox
vagrant box add jacqinthebox/windowsserver2016core --provider virtualbox

# For Vagrant Boxes Run Something Like This
#mkdir c:\packer
#cd c:\packer
#git clone https://github.com/mwrock/packer-templates.git
#cd packer-templates
#To run a build, run this command
#packer build -force-only virtalbox-iso .\vbox-2012r2.json

@"%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe" -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin"
choco install googlechrome 7zip notepadplusplus.install firefox git.install putty winscp.install azurestorageexplorer tortoisegit vagrant chefdk puppet-agent packer terraform virtualbox visualstudiocode vmwareworkstation -y
refreshenv
vagrant plugin install vagrant-winrm
vagrant plugin install vagrant-omnibus
vagrant plugin install vagrant-berkshelf
vagrant box add mwrock/Windows2016 --provider virtualbox
code --install-extension ms-vscode.powershell
code --install-extension msazurermtools.azurerm-vscode-tools
code --install-extension HookyQR.beautify
code --install-extension Pendrica.chef
code --install-extension ms-vscode.PeterJausovec.vscode-docker
code --install-extension alefragnani.project-manager
code --install-extension Borke.puppet
code --install-extension mauve.terraform
code --install-extension Pendrica.chef
code --install-extension bbenoist.vagrant
code --install-extension burtlo.inspec
code --install-extension ms-mssql.mssql
code --list-extensions

#Install Azure Powershell Cmdlets
downloadFile https://github.com/Azure/azure-powershell/releases/download/v4.2.1-July2017/azure-powershell.4.2.1.msi c:\windows\temp\
Start-Process c:\windows\temp\azure-powershell.4.2.1.msi -ArgumentList "/quiet /qn /norestart" -wait

#Pull this github repo as may be useful things i refer to later
mkdir c:\github
cd c:\github
git clone https://github.com/iaingblack/Automation.git

#This breaks the above commands by changing shell (I think) so do it last
chef gem install chef-zero-scheduled-task
chef gem install kitchen-all

#Add if required
vagrant box add mwrock/Windows2012R2 --provider virtualbox
vagrant box add jacqinthebox/windowsserver2016core --provider virtualbox

# For Vagrant Boxes Run Something Like This
#mkdir c:\packer
#cd c:\packer
#git clone https://github.com/mwrock/packer-templates.git
#cd packer-templates
#To run a build, run this command
#packer build -force-only virtalbox-iso .\vbox-2012r2.json

Update Vagrant.bat

Update Vagrant.bat


@echo off
cls

cd ".\src\Pickles\packages\NuGet.CommandLine.2.8.3\tools\"

".\NuGet.exe" "Install" "FAKE" "-OutputDirectory" "..\..\..\..\..\packages" "-ExcludeVersion"

cd ..\..\..\..\..

"packages\FAKE\tools\Fake.exe" build.fsx --envvar version 0.19.0
"packages\FAKE\tools\Fake.exe" nuget.fsx --envvar version 0.19.0
"packages\FAKE\tools\Fake.exe" chocolatey.fsx --envvar version 0.19.0

@echo off
set "picklesVersion=0.19.0"

cls

cd ".\src\Pickles\packages\NuGet.CommandLine.2.8.3\tools\"

".\NuGet.exe" "Install" "FAKE" "-OutputDirectory" "..\..\..\..\..\packages" "-ExcludeVersion"

cd ..\..\..\..\..

"packages\FAKE\tools\Fake.exe" build.fsx --envvar version %picklesVersion%
"packages\FAKE\tools\Fake.exe" nuget.fsx --envvar version %picklesVersion%
"packages\FAKE\tools\Fake.exe" chocolatey.fsx --envvar version %picklesVersion%

Set the version in an environment variable


set /p versionNumber=

del builds\Unquote-%versionNumber%.zip
del builds\Unquote.%versionNumber%.nupkg

REM preparing staging dirs

mkdir builds
mkdir staging
mkdir staging\net45
mkdir staging\profile259
copy LICENSE staging
copy NOTICE staging

REM building for net45 ...
"C:\Program Files (x86)\Microsoft SDKs\F#\3.1\Framework\v4.0\fsc.exe" -o:staging\net45\Unquote.dll --noframework --define:TRACE --doc:staging\net45\Unquote.xml --optimize+ -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.3.1.0\FSharp.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\mscorlib.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.Numerics.dll" --target:library --warn:3 --warnaserror:76 --vserrors --validate-type-providers --LCID:1033 --utf8output --fullpaths --flaterrors --subsystemversion:6.00 --highentropyva+ Unquote\Utils\Prelude.fs Unquote\Utils\Regex.fs Unquote\Utils\Printf.fs Unquote\Utils\List.fs Unquote\Utils\Type.fs Unquote\AssemblyInfo.fs Unquote\Prelude.fs Unquote\DynamicOperators.fs Unquote\EvaluationException.fs Unquote\Evaluation.fs Unquote\OperatorPrecedence.fs Unquote\ExtraReflection.fs Unquote\ExtraPatterns.fs Unquote\Decompilation.fs Unquote\Reduction.fs Unquote\Extensions.fs Unquote\Operators.fs Unquote\AssertionFailedException.fs Unquote\Assertions.fs

REM building for profile259
"C:\Program Files (x86)\Microsoft SDKs\F#\3.1\Framework\v4.0\fsc.exe" -o:staging\profile259\Unquote.dll --noframework --define:TRACE --define:PORTABLE --doc:staging\profile259\Unquote.xml --optimize+ -r:"C:\Program Files (x86)\MSBuild\..\Reference Assemblies\Microsoft\FSharp\.NETCore\3.259.3.1\FSharp.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\Microsoft.CSharp.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\mscorlib.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Collections.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ComponentModel.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ComponentModel.EventBasedAsync.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Diagnostics.Contracts.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Diagnostics.Debug.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Diagnostics.Tools.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Dynamic.Runtime.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Globalization.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.IO.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Linq.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Linq.Expressions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Linq.Queryable.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.NetworkInformation.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.Primitives.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.Requests.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ObjectModel.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Reflection.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Reflection.Extensions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Reflection.Primitives.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Resources.ResourceManager.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Extensions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.InteropServices.WindowsRuntime.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.Json.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.Primitives.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.Xml.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Security.Principal.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ServiceModel.Web.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Text.Encoding.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Text.Encoding.Extensions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Text.RegularExpressions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Threading.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Threading.Tasks.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Windows.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.Linq.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.ReaderWriter.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.Serialization.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.XDocument.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.XmlSerializer.dll" --target:library --warn:3 --warnaserror:76 --vserrors --validate-type-providers --LCID:1033 --utf8output --fullpaths --flaterrors --highentropyva- --targetprofile:netcore Unquote.Profile259\AssemblyInfo.fs Unquote\Utils\Prelude.fs Unquote\Utils\Regex.fs Unquote\Utils\Printf.fs Unquote\Utils\List.fs Unquote\Utils\Type.fs Unquote\Prelude.fs Unquote\DynamicOperators.fs Unquote\EvaluationException.fs Unquote\Evaluation.fs Unquote\OperatorPrecedence.fs Unquote\ExtraReflection.fs Unquote\ExtraPatterns.fs Unquote\Decompilation.fs Unquote\Reduction.fs Unquote\Extensions.fs Unquote\Operators.fs Unquote\AssertionFailedException.fs Unquote\Assertions.fs

REM zip builds ...
cd staging
..\tools\7z\7za.exe a -tzip ..\builds\Unquote-%versionNumber%.zip *
cd ..

REM preparing nuget dirs

mkdir nuget
mkdir nuget\lib
mkdir nuget\lib\net45
mkdir "nuget\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1"
copy Unquote.nuspec nuget

REM copy staging builds to nuget package...

copy staging\net45\Unquote.dll nuget\lib\net45\Unquote.dll
copy staging\net45\Unquote.xml nuget\lib\net45\Unquote.xml
copy staging\profile259\Unquote.dll "nuget\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1\Unquote.dll"
copy staging\profile259\Unquote.xml "nuget\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1\Unquote.xml"

REM create nuget package...

".nuget\nuget.exe" pack nuget\Unquote.nuspec -Version %versionNumber%
copy Unquote.%versionNumber%.nupkg builds
del Unquote.%versionNumber%.nupkg

REM cleanup...

rd /q /s staging
rd /q /s nuget

pause

set /p versionNumber=

del builds\Unquote-%versionNumber%.zip
del builds\Unquote.%versionNumber%.nupkg

REM preparing staging dirs

mkdir builds
mkdir staging
mkdir staging\net45
mkdir staging\profile259
mkdir staging\net40
copy LICENSE staging
copy NOTICE staging

REM building for net45 ...
"C:\Program Files (x86)\Microsoft SDKs\F#\3.1\Framework\v4.0\fsc.exe" -o:staging\net45\Unquote.dll --noframework --define:TRACE --doc:staging\net45\Unquote.xml --optimize+ -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.3.1.0\FSharp.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\mscorlib.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.Numerics.dll" --target:library --warn:3 --warnaserror:76 --vserrors --validate-type-providers --LCID:1033 --utf8output --fullpaths --flaterrors --subsystemversion:6.00 --highentropyva+ Unquote\Utils\Prelude.fs Unquote\Utils\Regex.fs Unquote\Utils\Printf.fs Unquote\Utils\List.fs Unquote\Utils\Type.fs Unquote\AssemblyInfo.fs Unquote\Prelude.fs Unquote\DynamicOperators.fs Unquote\EvaluationException.fs Unquote\Evaluation.fs Unquote\OperatorPrecedence.fs Unquote\ExtraReflection.fs Unquote\ExtraPatterns.fs Unquote\Decompilation.fs Unquote\Reduction.fs Unquote\Extensions.fs Unquote\Operators.fs Unquote\AssertionFailedException.fs Unquote\Assertions.fs

REM building for profile259
"C:\Program Files (x86)\Microsoft SDKs\F#\3.1\Framework\v4.0\fsc.exe" -o:staging\profile259\Unquote.dll --noframework --define:TRACE --define:PORTABLE --doc:staging\profile259\Unquote.xml --optimize+ -r:"C:\Program Files (x86)\MSBuild\..\Reference Assemblies\Microsoft\FSharp\.NETCore\3.259.3.1\FSharp.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\Microsoft.CSharp.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\mscorlib.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Collections.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ComponentModel.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ComponentModel.EventBasedAsync.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Diagnostics.Contracts.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Diagnostics.Debug.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Diagnostics.Tools.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Dynamic.Runtime.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Globalization.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.IO.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Linq.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Linq.Expressions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Linq.Queryable.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.NetworkInformation.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.Primitives.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Net.Requests.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ObjectModel.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Reflection.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Reflection.Extensions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Reflection.Primitives.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Resources.ResourceManager.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Extensions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.InteropServices.WindowsRuntime.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.Json.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.Primitives.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Runtime.Serialization.Xml.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Security.Principal.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.ServiceModel.Web.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Text.Encoding.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Text.Encoding.Extensions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Text.RegularExpressions.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Threading.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Threading.Tasks.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Windows.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.Linq.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.ReaderWriter.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.Serialization.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.XDocument.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile259\System.Xml.XmlSerializer.dll" --target:library --warn:3 --warnaserror:76 --vserrors --validate-type-providers --LCID:1033 --utf8output --fullpaths --flaterrors --highentropyva- --targetprofile:netcore Unquote.Profile259\AssemblyInfo.fs Unquote\Utils\Prelude.fs Unquote\Utils\Regex.fs Unquote\Utils\Printf.fs Unquote\Utils\List.fs Unquote\Utils\Type.fs Unquote\Prelude.fs Unquote\DynamicOperators.fs Unquote\EvaluationException.fs Unquote\Evaluation.fs Unquote\OperatorPrecedence.fs Unquote\ExtraReflection.fs Unquote\ExtraPatterns.fs Unquote\Decompilation.fs Unquote\Reduction.fs Unquote\Extensions.fs Unquote\Operators.fs Unquote\AssertionFailedException.fs Unquote\Assertions.fs

REM building for net40
"C:\Program Files (x86)\Microsoft F#\v4.0\fsc.exe" -o:staging\net40\Unquote.dll --noframework --define:TRACE --define:NET40 --doc:staging\net40\Unquote.xml --optimize+ -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\2.0\Runtime\v4.0\FSharp.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\mscorlib.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\System.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\System.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\System.Numerics.dll" --target:library --warn:3 --warnaserror:76 --vserrors --LCID:1033 --utf8output --fullpaths --flaterrors Unquote.Net40\AssemblyInfo.fs Unquote\Utils\Prelude.fs Unquote\Utils\Regex.fs Unquote\Utils\Printf.fs Unquote\Utils\List.fs Unquote\Utils\Type.fs Unquote\Prelude.fs Unquote\DynamicOperators.fs Unquote\EvaluationException.fs Unquote\Evaluation.fs Unquote\OperatorPrecedence.fs Unquote\ExtraReflection.fs Unquote\ExtraPatterns.fs Unquote\Decompilation.fs Unquote\Reduction.fs Unquote\Extensions.fs Unquote\Operators.fs Unquote\AssertionFailedException.fs Unquote\Assertions.fs

REM zip builds ...
cd staging
..\tools\7z\7za.exe a -tzip ..\builds\Unquote-%versionNumber%.zip *
cd ..

REM preparing nuget dirs

mkdir nuget
mkdir nuget\lib
mkdir nuget\lib\net45
mkdir "nuget\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1"
mkdir nuget\lib\net40
copy Unquote.nuspec nuget

REM copy staging builds to nuget package...

copy staging\net45\Unquote.dll nuget\lib\net45\Unquote.dll
copy staging\net45\Unquote.xml nuget\lib\net45\Unquote.xml
copy staging\profile259\Unquote.dll "nuget\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1\Unquote.dll"
copy staging\profile259\Unquote.xml "nuget\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1\Unquote.xml"
copy staging\net40\Unquote.dll nuget\lib\net40\Unquote.dll
copy staging\net40\Unquote.xml nuget\lib\net40\Unquote.xml

REM create nuget package...

".nuget\nuget.exe" pack nuget\Unquote.nuspec -Version %versionNumber%
copy Unquote.%versionNumber%.nupkg builds
del Unquote.%versionNumber%.nupkg

REM cleanup...

rd /q /s staging
rd /q /s nuget

pause

include .net40 in bat build script

include .net40 in bat build script


@echo off
cls

paket.exe restore
if errorlevel 1 (
  exit /b %errorlevel%
)

packages\build\FAKE\tools\FAKE.exe build.fsx %* --nocache

@echo off
cls

paket.exe restore
if errorlevel 1 (
  exit /b %errorlevel%
)

dir
dir packages
dir packages\build
dir packages\build\FAKE
dir packages\build\FAKE\tools\
packages\build\FAKE\tools\FAKE.exe build.fsx %* --nocache

Debug appveyor 2

Debug appveyor 2


@echo off
cd %~dp0

SETLOCAL
SET CACHED_NUGET=%LocalAppData%\NuGet\NuGet.exe
SET BUILDCMD_KOREBUILD_VERSION=""
SET BUILDCMD_DNX_VERSION=""

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
IF %BUILDCMD_KOREBUILD_VERSION%=="" (
	.nuget\NuGet.exe install KoreBuild -ExcludeVersion -o packages -nocache -pre
) ELSE (
	.nuget\NuGet.exe install KoreBuild -version %BUILDCMD_KOREBUILD_VERSION% -ExcludeVersion -o packages -nocache -pre
)
.nuget\NuGet.exe install Sake -version 0.2 -o packages -ExcludeVersion

IF "%SKIP_DNX_INSTALL%"=="1" goto run
IF %BUILDCMD_DNX_VERSION%=="" (
	CALL packages\KoreBuild\build\dnvm upgrade -runtime CLR -arch x86
) ELSE (
	CALL packages\KoreBuild\build\dnvm install %BUILDCMD_DNX_VERSION% -runtime CLR -arch x86 -a default
)
CALL packages\KoreBuild\build\dnvm install default -runtime CoreCLR -arch x86

:run
CALL packages\KoreBuild\build\dnvm use default -runtime CLR -arch x86
packages\Sake\tools\Sake.exe -I packages\KoreBuild\build -f makefile.shade %*

@echo off
cd %~dp0

SETLOCAL
SET CACHED_NUGET=%LocalAppData%\NuGet\NuGet.exe
SET BUILDCMD_KOREBUILD_VERSION=""
SET BUILDCMD_DNX_VERSION=""

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
IF %BUILDCMD_KOREBUILD_VERSION%=="" (
	.nuget\NuGet.exe install KoreBuild -ExcludeVersion -o packages -nocache -pre
) ELSE (
	.nuget\NuGet.exe install KoreBuild -version %BUILDCMD_KOREBUILD_VERSION% -ExcludeVersion -o packages -nocache -pre
)
.nuget\NuGet.exe install Sake -ExcludeVersion -Source https://www.nuget.org/api/v2/ -Out packages

IF "%SKIP_DNX_INSTALL%"=="1" goto run
IF %BUILDCMD_DNX_VERSION%=="" (
	CALL packages\KoreBuild\build\dnvm upgrade -runtime CLR -arch x86
) ELSE (
	CALL packages\KoreBuild\build\dnvm install %BUILDCMD_DNX_VERSION% -runtime CLR -arch x86 -a default
)
CALL packages\KoreBuild\build\dnvm install default -runtime CoreCLR -arch x86

:run
CALL packages\KoreBuild\build\dnvm use default -runtime CLR -arch x86
packages\Sake\tools\Sake.exe -I packages\KoreBuild\build -f makefile.shade %*

Update 'build.cmd' to pull Sake from v2 NuGet feed.


@echo off
setlocal
cd "%~dp0"
set MSBUILDEXE=%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe
if not exist "%MSBUILDEXE%" (
    echo The .NET Framework 4.0 does not appear to be installed on this
    echo machine, which is required to build the solution.
    exit /b 1
)
if "%1"=="docs" call :docs %2 %3 %4 %5 %6 %7 %8 %9 & goto :EOF

:base
for %%i in (debug release) do "%MSBUILDEXE%" "MoreLinq.sln" /v:m /p:Configuration=%%i %*
goto :EOF

:docs
call :base
"%MSBUILDEXE%" MoreLinq.shfbproj %*
goto :EOF

@echo off
setlocal
cd "%~dp0"
set MSBUILDEXE=%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe
if not exist "%MSBUILDEXE%" (
    echo The .NET Framework 4.0 does not appear to be installed on this
    echo machine, which is required to build the solution.
    exit /b 1
)
if "%1"=="docs" call :docs %2 %3 %4 %5 %6 %7 %8 %9 & goto :EOF

:base
for %%i in (debug release) do "%MSBUILDEXE%" "MoreLinq.sln" /v:m /p:Configuration=%%i %*
goto :EOF

:docs
call :base && "%MSBUILDEXE%" MoreLinq.shfbproj %*
goto :EOF

Build docs only if code build succeeds

Build docs only if code build succeeds


@ECHO OFF
CD %~dp0

SETLOCAL

IF NOT DEFINED VisualStudioVersion (
    IF DEFINED VS140COMNTOOLS (
        CALL "%VS140COMNTOOLS%\VsDevCmd.bat"
        GOTO :EnvSet
    )

    ECHO Error: build.cmd requires Visual Studio 2015.
    SET ERRORLEVEL=1
    GOTO :Exit
)

:EnvSet
SET DNU_EXE=dnu
SET _buildproj=%~dp0All.sln

:: Check if DNU exists globally
WHERE %DNU_EXE%

IF NOT '%ERRORLEVEL%'=='0' (
    ECHO ERROR: build.cmd requires dnu installed gloablly.
    GOTO :Exit
)

:: Restore packages for .csproj projects

CALL :RestorePackage

:: Log build command line
SET _buildlog=%~dp0msbuild.log
SET _buildprefix=echo
SET _buildpostfix=^> "%_buildlog%"
CALL :Build %*

:: Build
SET _buildprefix=
SET _buildpostfix=
CALL :Build %*

GOTO :AfterBuild

:AfterBuild

:: Pull the build summary from the log file
ECHO.
ECHO === BUILD RESULT ===
findstr /ir /c:".*Warning(s)" /c:".*Error(s)" /c:"Time Elapsed.*" "%_buildlog%"

:: Pull xunit test result from the log file
ECHO.
ECHO === TEST EXECUTION SUMMARY ===
findstr /ir /c:"Total:.*Failed.*Skipped.*Time.*" "%_buildlog%"

GOTO :Exit

:Build
%_buildprefix% msbuild "%_buildproj%" /nologo /maxcpucount /verbosity:minimal /nodeReuse:false /fileloggerparameters:Verbosity=diag;LogFile="%_buildlog%";Append %* %_buildpostfix%

:RestorePackage
:: Restore inside each subfolder
FOR /D %%x IN ("src","docs","test") DO (
PUSHD %%x
CMD /C %DNU_EXE% restore --parallel
POPD
)

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

:RESTORE
:: Currently has corpnet dependency
.NuGet\NuGet.exe restore "%_buildproj%"

:Exit
ECHO.
ECHO Exit Code = %ERRORLEVEL%
EXIT /B %ERRORLEVEL%

@ECHO OFF
PUSHD %~dp0

SETLOCAL

IF NOT DEFINED VisualStudioVersion (
    IF DEFINED VS140COMNTOOLS (
        CALL "%VS140COMNTOOLS%\VsDevCmd.bat"
        GOTO :EnvSet
    )

    ECHO Error: build.cmd requires Visual Studio 2015.
    SET ERRORLEVEL=1
    GOTO :Exit
)

:EnvSet
SET DnuExe=dnu
SET BuildProj=%~dp0All.sln

:: Check if DNU exists globally
WHERE %DnuExe%

IF NOT '%ERRORLEVEL%'=='0' (
    ECHO ERROR: build.cmd requires dnu installed gloablly.
    GOTO :Exit
)

:: Restore packages for .csproj projects

CALL :RestorePackage

:: Log build command line
SET BuildLog=%~dp0msbuild.log
SET BuildPrefix=echo
SET BuildPostfix=^> "%BuildLog%"
CALL :Build %*

:: Build
SET BuildPrefix=
SET BuildPostfix=
CALL :Build %*

GOTO :AfterBuild

:AfterBuild

:: Pull the build summary from the log file
ECHO.
ECHO === BUILD RESULT ===
findstr /ir /c:".*Warning(s)" /c:".*Error(s)" /c:"Time Elapsed.*" "%BuildLog%"

:: Pull xunit test result from the log file
ECHO.
ECHO === TEST EXECUTION SUMMARY ===
findstr /ir /c:"Total:.*Failed.*Skipped.*Time.*" "%BuildLog%"

GOTO :Exit

:Build
%BuildPrefix% msbuild "%BuildProj%" /nologo /maxcpucount /verbosity:minimal /nodeReuse:false /fileloggerparameters:Verbosity=diag;LogFile="%BuildLog%";Append %* %BuildPostfix%

:RestorePackage
:: Restore inside each subfolder
FOR /D %%x IN ("src","docs","test") DO (
PUSHD %%x
CMD /C %DnuExe% restore --parallel
POPD
)

SET CachedNuget=%LocalAppData%\NuGet\NuGet.exe

IF EXIST %CachedNuget% 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 '%CachedNuget%'"

:COPYNUGET
IF EXIST .NuGet\NuGet.exe GOTO RESTORE
MD .NuGet
COPY %CachedNuget% .NuGet\NuGet.exe

:RESTORE
:: Currently has corpnet dependency
.NuGet\NuGet.exe restore "%BuildProj%"

:Exit
POPD
ECHO.
ECHO Exit Code = %ERRORLEVEL%
EXIT /B %ERRORLEVEL%

Resolve comments

Resolve comments


Update language/tests/build.bat - This is important to isolate test.exe from ring.dll - To avoid failure in test.exe when we update Ring source code and do a mistake, We need that the mistakes appears in the Tests - Not in test.exe itself because of a problem in ring.dll (Ring VM)


:: Script to trim size of unpacked build output.
:: Removes extraneous contents not required to run Zephyr.
:: Expected to be run from `.scripts` directory.

@ECHO off
set WORKING_DIRECTORY=..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\node-openvr

:: Check that working directory exists
IF NOT EXIST %WORKING_DIRECTORY% (
    echo Unable to find directory: %WORKING_DIRECTORY%
    exit /b 1
)

:: Naive check that script hasn't already run
IF NOT EXIST %WORKING_DIRECTORY%\overlay (
    echo Already trimmed!
    exit
)

echo Cleaning up...

:: Cleanup OpenVR directory
rmdir /s /q %WORKING_DIRECTORY%\lib\openvr\bin
rmdir /s /q %WORKING_DIRECTORY%\lib\openvr\controller_callouts
rmdir /s /q %WORKING_DIRECTORY%\lib\openvr\lib
rmdir /s /q %WORKING_DIRECTORY%\lib\openvr\samples
rmdir /s /q %WORKING_DIRECTORY%\lib\openvr\src
del %WORKING_DIRECTORY%\lib\openvr\CMakeLists.txt
del %WORKING_DIRECTORY%\lib\openvr\README.md
del %WORKING_DIRECTORY%\lib\openvr\Toolchain-clang.cmake

:: Remove other directories/files
rmdir /s /q %WORKING_DIRECTORY%\overlay
rmdir /s /q %WORKING_DIRECTORY%\samples
rmdir /s /q %WORKING_DIRECTORY%\src
rmdir /s /q %WORKING_DIRECTORY%\tools
del %WORKING_DIRECTORY%\.gitmodules

echo Done!

Add script to reduce distributable size from 358 MB to 162 MB


@REM
@REM Copyright (c) 2013 mgm technology partners GmbH
@REM
@REM Licensed under the Apache License, Version 2.0 (the "License");
@REM you may not use this file except in compliance with the License.
@REM You may obtain a copy of the License at
@REM
@REM     http://www.apache.org/licenses/LICENSE-2.0
@REM
@REM Unless required by applicable law or agreed to in writing, software
@REM distributed under the License is distributed on an "AS IS" BASIS,
@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@REM See the License for the specific language governing permissions and
@REM limitations under the License.
@REM

@echo off
@setlocal

set ARGS=tasks
if not "%1" == "" set ARGS=%*

cd %~dp0

if exist setenv.cmd call setenv.cmd

gradlew.cmd -q -b Supervisor.gradle %ARGS%

@endlocal

Fix line endings

Fix line endings

Change-Id: I8690f6fcb4c8f7f47c997d2cfa9f3cb356de397f


@echo off
@pushd %~dp0

ECHO Remember to build the solution first!

pause

"%~dp0\TestHarness\packages\NUnit.Runners.2.6.4\tools\nunit-console.exe" "%~dp0\TestHarness\nunit\bin\Debug\nunitHarness.dll" /result="%~dp0\results-example-nunit.xml"

"%~dp0\TestHarness\packages\NUnit.Console.3.0.0\tools\nunit3-console.exe" "%~dp0\TestHarness\nunit3\bin\Debug\nunit3Harness.dll" /result="%~dp0\results-example-nunit3.xml"

"%~dp0\TestHarness\packages\SpecRun.Runner.1.2.0\tools\specrun.exe" run default.srprofile "/baseFolder:%~dp0\TestHarness\SpecRun\bin\Debug" /log:specrun.log /report:"%~dp0\results-example-specrun.html"

"%~dp0\TestHarness\packagesNonNuget\xunit.runner\xunit.console.clr4.exe" "%~dp0\TestHarness\xunit\bin\Debug\xunitHarness.dll" /xml "%~dp0\results-example-xunit.xml"

"%~dp0\TestHarness\packages\xunit.runner.console.2.1.0\tools\xunit.console.exe" "%~dp0\TestHarness\xunit2\bin\Debug\xunit2Harness.dll" -xml "%~dp0\results-example-xunit2.xml" -parallel none

del "%~dp0\results-example-mstest.trx"
"%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\Common7\IDE\MSTest.exe" /testcontainer:"%~dp0\TestHarness\mstest\bin\Debug\mstestHarness.dll" /resultsfile:"%~dp0\results-example-mstest.trx" /testsettings:"%~dp0\TestHarness\TestSettings.testsettings"

cd "%~dp0\TestHarness\Cucumber"
cucumber --format json_pretty --out "%~dp0\results-example.json.json" --tags ~@ignore
cd "%~dp0"

@popd

@echo off
@pushd %~dp0

ECHO Remember to build the solution first!

pause

"%~dp0\TestHarness\packages\NUnit.Runners.2.6.4\tools\nunit-console.exe" "%~dp0\TestHarness\nunit\bin\Debug\nunitHarness.dll" /result="%~dp0\results-example-nunit.xml"

"%~dp0\TestHarness\packages\NUnit.Console.3.0.0\tools\nunit3-console.exe" "%~dp0\TestHarness\nunit3\bin\Debug\nunit3Harness.dll" /result="%~dp0\results-example-nunit3.xml"

"%~dp0\TestHarness\packages\SpecRun.Runner.1.2.0\tools\specrun.exe" run default.srprofile "/baseFolder:%~dp0\TestHarness\SpecRun\bin\Debug" /log:specrun.log /report:"%~dp0\results-example-specrun.html"

"%~dp0\TestHarness\packagesNonNuget\xunit.runner\xunit.console.clr4.exe" "%~dp0\TestHarness\xunit\bin\Debug\xunitHarness.dll" /xml "%~dp0\results-example-xunit.xml"

"%~dp0\TestHarness\packages\xunit.runner.console.2.1.0\tools\xunit.console.exe" "%~dp0\TestHarness\xunit2\bin\Debug\xunit2Harness.dll" -xml "%~dp0\results-example-xunit2.xml" -parallel none

del "%~dp0\results-example-mstest.trx"
"%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\Common7\IDE\MSTest.exe" /testcontainer:"%~dp0\TestHarness\mstest\bin\Debug\mstestHarness.dll" /resultsfile:"%~dp0\results-example-mstest.trx" /testsettings:"%~dp0\TestHarness\TestSettings.testsettings"

cd "%~dp0\TestHarness\Cucumber"
cucumber --format json_pretty --out "%~dp0\results-example-json.json" --tags ~@ignore
cd "%~dp0"

@popd

Change name of generated file

Change name of generated file


REM This file should be executed from the command line prior to the first
REM build.  It will be necessary to refresh the Eclipse project once the
REM .bat file has been executed (normally just press F5 to refresh).

REM Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Eclipse project directory.
REM This permits the Eclipse project to be used in 'managed' mode and without
REM having to setup any linked resources.

REM Have the files already been copied?
IF EXIST RTOSDemo\FreeRTOS Goto END

	REM Create the required directory structure.
	MD RTOSDemo\FreeRTOS
	MD RTOSDemo\FreeRTOS\include
	MD RTOSDemo\FreeRTOS\portable\GCC\NiosII
	MD RTOSDemo\FreeRTOS\portable\MemMang
	MD "RTOSDemo\Common_Demo_Tasks"
	MD "RTOSDemo\Common_Demo_Tasks\include"

	REM Copy the core kernel files.
	copy ..\..\Source\tasks.c RTOSDemo\FreeRTOS
	copy ..\..\Source\queue.c RTOSDemo\FreeRTOS
	copy ..\..\Source\list.c RTOSDemo\FreeRTOS

	REM Copy the common header files

	copy ..\..\Source\include\*.* RTOSDemo\FreeRTOS\include

	REM Copy the portable layer files
	copy ..\..\Source\portable\GCC\NiosII\*.* RTOSDemo\FreeRTOS\portable\GCC\NiosII

	REM Copy the basic memory allocation files
	copy ..\..\Source\portable\MemMang\*.* RTOSDemo\FreeRTOS\portable\MemMang

	REM Copy the files that define the Common_Demo_Tasks.
	copy ..\Common\minimal\BlockQ.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\blocktim.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\comtest.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\countsem.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\death.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\dynamic.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\flash.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\GenQTest.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\integer.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\PollQ.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\QPeek.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\recmutex.c "RTOSDemo\Common_Demo_Tasks"
	copy ..\Common\minimal\semtest.c "RTOSDemo\Common_Demo_Tasks"

	REM Copy the common demo file headers.
	copy ..\Common\include\*.* "RTOSDemo\Common_Demo_Tasks\include"

: END

Add batch file to create the NiosII project directory structure.


pushd ..\gen
call update
popd
cl -I../ -DXBYAK_TEST jmp.cpp %OPT% /Od /Zi
jmp

pushd ..\gen
call update
popd
cl -I../ -I./ -DXBYAK_TEST jmp.cpp %OPT% /Od /Zi
jmp

add build path

add build path


### application.bat - 201x - Velez Damien ###
version = "2"
build_hour = "11H00"

echo "Build ${build_hour}"
echo "version ${version}"

### application.bat - 201x - Velez Damien ###
version = "1.2.0-b"
build_hour = "11H00"

echo "Build ${build_hour}"
echo "version ${version}"

update minor alternative version

update minor alternative version


@echo off
REM
REM This is intended to be a convenience file when the layout
REM is something like this:
REM
REM python\
REM   make.cmd (this file)
REM   python-dev\
REM     make.py
REM     configure.ini
REM   issue12345\
REM     (a python clone)
REM   issue56789\
REM     (a different python clone)
REM
REM You would normally be inside one of the Python clones and then calling
REM ..\make
REM
FOR /F %%d IN ('%~d0%~p0\python-dev\clone.py %*') DO CD %%d
..\make externals

@echo off
REM
REM This is intended to be a convenience file when the layout
REM is something like this:
REM
REM python\
REM   make.cmd (this file)
REM   python-dev\
REM     make.py
REM     configure.ini
REM   issue12345\
REM     (a python clone)
REM   issue56789\
REM     (a different python clone)
REM
REM You would normally be inside one of the Python clones and then calling
REM ..\make
REM
FOR /F %%d IN ('%~d0%~p0\python-dev\clone.py %*') DO CD %%d
call make externals

Check out externals once cloned

Check out externals once cloned


@echo off
setlocal
if "%BUILDER_TOP_DIR%" == "" (
    echo Error: BUILDER_TOP_DIR is not set
    goto :eof
)
set PYTHONPATH=%BUILDER_TOP_DIR%\Source\Scm;%BUILDER_TOP_DIR%\Source\Common;%BUILDER_TOP_DIR%\Source\Git;%BUILDER_TOP_DIR%\Source\Svn;%BUILDER_TOP_DIR%\Source\Hg

cd ..\Common
%PYTHON% make_wb_diff_images.py
    if errorlevel 1 goto :eof

cd ..\Scm
nmake -f windows.mak clean
    if errorlevel 1 goto :eof
nmake -f windows.mak all
    if errorlevel 1 goto :eof

set PROG=scm_workbench_git_callback.cmd
echo "%PYTHON%" "%BUILDER_TOP_DIR%\Source\Git\wb_git_callback_client_win32.py" %%1 %%2 >%PROG%

set BUILDER_START_DIR=
set BUILDER_TOP_DIR=
set BUILDROOT_DIR=

echo on
echo PYTHONPATH %PYTHONPATH%
%PYTHON% wb_scm_main.py %*
if errorlevel 1 echo Error: wb_scm_main exited with error
endlocal

@echo off
setlocal
if "%BUILDER_TOP_DIR%" == "" (
    echo Error: BUILDER_TOP_DIR is not set
    echo Make sure Builder\builder_custom_init.cmd has been run
    goto :eof
)
if "%PYTHON%" == "" (
    echo Error: PYTHON is not set
    echo Make sure Builder\builder_custom_init.cmd has been run
    goto :eof
)

set PYTHONPATH=%BUILDER_TOP_DIR%\Source\Scm;%BUILDER_TOP_DIR%\Source\Common;%BUILDER_TOP_DIR%\Source\Git;%BUILDER_TOP_DIR%\Source\Svn;%BUILDER_TOP_DIR%\Source\Hg

cd ..\Common
%PYTHON% make_wb_diff_images.py
    if errorlevel 1 goto :eof

cd ..\Scm
nmake -f windows.mak clean
    if errorlevel 1 goto :eof
nmake -f windows.mak all
    if errorlevel 1 goto :eof

set PROG=scm_workbench_git_callback.cmd
echo "%PYTHON%" "%BUILDER_TOP_DIR%\Source\Git\wb_git_callback_client_win32.py" %%1 %%2 >%PROG%

set BUILDER_START_DIR=
set BUILDER_TOP_DIR=
set BUILDROOT_DIR=

echo on
echo PYTHONPATH %PYTHONPATH%
%PYTHON% wb_scm_main.py %*
if errorlevel 1 echo Error: wb_scm_main exited with error
endlocal

Add move misconfig detection

Add move misconfig detection


@echo off
cls
java -Dj3d.rend=d3d -Djava.util.logging.config.file=conf/logging.properties -Xms512m -Xmx1384m -cp MZmine.jar net.sf.mzmine.main.MZmineClient

@echo off
cls
java -Dj3d.rend=d3d -Djava.library.path=lib -Djava.util.logging.config.file=conf/logging.properties -Xms512m -Xmx1384m -cp MZmine.jar net.sf.mzmine.main.MZmineClient

Complete implementation of module io running as a task.


@ECHO OFF

SET pluginVersion=0.21

for %%X in (2017.2 2017.3 2018.1 2018.2 183.2153.8) do call :buildPlugin %%X
ECHO All Done

echo.&pause&goto:eof

:buildPlugin
SETLOCAL
echo Called with %1
SET IDEA_VERSION=%1
call gradlew clean build
xcopy build\distributions\lombok-plugin-%pluginVersion%.zip distro\lombok-plugin-%pluginVersion%-%1.zip*
ENDLOCAL & SET result=%retval%

@ECHO OFF

SET pluginVersion=0.21

for %%X in (2017.2 2017.3 2018.1 2018.2 183.2153.8) do call :buildPlugin %%X
ECHO All Done

echo.&pause&goto:eof

:buildPlugin
SETLOCAL
echo Called with %1
SET IDEA_VERSION=%1
call gradlew clean
call gradlew build
xcopy build\distributions\lombok-plugin-%pluginVersion%.zip distro\lombok-plugin-%pluginVersion%-%1.zip*
ENDLOCAL & SET result=%retval%

fix script

fix script

GitOrigin-RevId: eac75efeec636aba54ed7920899ac4a13a3db939


@echo off

set MINGW_PATH=C:\usr\share\ruby\ruby\devkit-mingw64-64\mingw\bin
path=C:\usr\share\CMake\bin;%MINGW_PATH%

goto :%buildtype%

:generate
    if not exist "%builddir%" ( mkdir "%builddir%" )
    set arg=-G "MinGW Makefiles" -D CMAKE_PROGRAM_PATH=%MINGW_PATH% -D CMAKE_BUILD_TYPE=%buildconfig% "%srcdir%"
    goto :cmake

:build
    set arg=--build %builddir% --config %buildconfig%
    goto :cmake

:distclean
    rmdir /q /s "%builddir%"
    exit /b 0

:clean
    set arg=--build %builddir% --target clean
    goto :cmake

:cmake
pushd %builddir%
cmake  %arg%
popd

@echo off

set MINGW_PATH=C:\usr\share\ruby\ruby\devkit-mingw64-64\mingw\bin

goto :%buildtype%

:generate
    if not exist "%builddir%" ( mkdir "%builddir%" )
    set arg=-G "MinGW Makefiles" -D CMAKE_PROGRAM_PATH=%MINGW_PATH% -D CMAKE_BUILD_TYPE=%buildconfig% "%srcdir%"
    goto :cmake

:build
    set arg=--build %builddir% --config %buildconfig%
    goto :cmake

:distclean
    rmdir /q /s "%builddir%"
    exit /b 0

:clean
    set arg=--build %builddir% --target clean
    goto :cmake

:cmake
pushd %builddir%
cmake  %arg%
popd

remove test code

remove test code


cd "C:\Users\fred\Documents\Visual Studio 2012\Projects"
cd AddFeatures
git pull origin master
cd ..
cd CodeGeneration
git pull origin master
cd ..
cd PaperBoy
git pull origin master
cd ..
cd fredatgithub.github.io
git pull origin master
cd ..
cd MyFavoriteQuotes
git pull origin master
cd ..
cd WinFormTemplate
git pull origin master
cd ..
cd UsefulFunctions
git pull origin master
cd ..
cd YouTubeVideoName
git pull origin master
cd ..
cd CharacterPermutations
git pull origin master
cd ..
cd MRUManager
git pull origin master
cd ..
cd uptime
git pull origin master
cd ..
cd Matrix
git pull origin master
cd ..
cd Chronometre
git pull origin master
cd ..
cd GitAutoUpdate
git pull origin master
cd ..

Add one repository

Add one repository


@echo off

rem This script is in use by the Windows buildslaves to upload the package to openphdguiding.org

for /F "usebackq" %%f in (`dir phd2-*-win32.exe /O-D /B` ) do (
  if EXIST %%f (
   (
   echo cd upload
   echo put %%f
   echo quit
   ) | psftp phd2buildbot@openphdguiding.org
  )
  goto :end
)

:end

@echo off

rem This script is in use by the Windows buildslaves to upload the package to openphdguiding.org

set exitcode=1

for /F "usebackq" %%f in (`dir phd2-*-win32.exe /O-D /B` ) do (
  if EXIST %%f (
   (
   echo cd upload
   echo put %%f
   echo quit
   ) | psftp phd2buildbot@openphdguiding.org
   set exitcode=%errorlevel%
  )
  goto :end
)

:end
exit /B %exitcode%

Check upload success

Check upload success


if not exist "C:\Windows\Temp\7z920-x64.msi" (
    powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::TLS12; (New-Object System.Net.WebClient).DownloadFile('http://www.7-zip.org/a/7z920-x64.msi', 'C:\Windows\Temp\7z920-x64.msi')" <NUL
    msiexec /qb /i C:\Windows\Temp\7z920-x64.msi
)

if exist "C:\Users\vagrant\windows.iso" (
    move /Y C:\Users\vagrant\windows.iso C:\Windows\Temp
)

if not exist "C:\Windows\Temp\windows.iso" (
    powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::TLS12; (New-Object System.Net.WebClient).DownloadFile('http://softwareupdate.vmware.com/cds/vmw-desktop/ws/12.5.5/5234757/windows/packages/tools-windows.tar', 'C:\Windows\Temp\vmware-tools.tar')" <NUL
    cmd /c ""C:\Program Files\7-Zip\7z.exe" x C:\Windows\Temp\vmware-tools.tar -oC:\Windows\Temp"
    FOR /r "C:\Windows\Temp" %%a in (VMware-tools-windows-*.iso) DO REN "%%~a" "windows.iso"
    rd /S /Q "C:\Program Files (x86)\VMWare"
)

cmd /c ""C:\Program Files\7-Zip\7z.exe" x C:\Windows\Temp\windows.iso -oC:\Windows\Temp\VMware"
cmd /c "C:\Windows\Temp\VMware\setup64.exe /s /v/qb"

rd /S /Q "C:\Windows\Temp\VMware"

if not exist "C:\Windows\Temp\7z920-x64.msi" (
    powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::TLS12; (New-Object System.Net.WebClient).DownloadFile('http://www.7-zip.org/a/7z920-x64.msi', 'C:\Windows\Temp\7z920-x64.msi')" <NUL
    msiexec /qb /i C:\Windows\Temp\7z920-x64.msi
)

if exist "C:\Users\vagrant\windows.iso" (
    move /Y C:\Users\vagrant\windows.iso C:\Windows\Temp
)

if not exist "C:\Windows\Temp\windows.iso" (
    powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::TLS12; (New-Object System.Net.WebClient).DownloadFile('http://softwareupdate.vmware.com/cds/vmw-desktop/ws/12.5.5/5234757/windows/packages/tools-windows.tar', 'C:\Windows\Temp\vmware-tools.tar')" <NUL
    cmd /c ""C:\Program Files\7-Zip\7z.exe" x C:\Windows\Temp\vmware-tools.tar -oC:\Windows\Temp"
    FOR /r "C:\Windows\Temp" %%a in (VMware-tools-windows-*.iso) DO REN "%%~a" "windows.iso"
    rd /S /Q "C:\Program Files (x86)\VMWare"
)

cmd /c ""C:\Program Files\7-Zip\7z.exe" x C:\Windows\Temp\windows.iso -oC:\Windows\Temp\VMware"
cmd /c "C:\Windows\Temp\VMware\setup64.exe /s /v/qb /v/norestart"

rd /S /Q "C:\Windows\Temp\VMware"

Include no restart option for tools install


@echo off

SETLOCAL

SET EXEC=%~0
SET ISSUE=%1

REM split exec into parts
For %%F IN ("%EXEC%") do (
	Set FOLDER=%%~dpF
	Set NAME=%%~nxF
)

REM test if we have an issue nr
if [%1] == [] GOTO :NoIssue
SET SPECS=%FOLDER%..\sass-spec\spec

if not exist "%ISSUE%.scss" (
  echo input source not found: %ISSUE%.scss
  goto :End
)

SET GITCMD=git -C "%FOLDER%..\sass-spec"

%GITCMD% fetch --all
%GITCMD% checkout -f -B todo/issue_%ISSUE% master

if not exist "%SPECS%\libsass-todo-issues\issue_%ISSUE%" (
  mkdir "%SPECS%\libsass-todo-issues\issue_%ISSUE%"
)

copy %ISSUE%.scss %SPECS%\libsass-todo-issues\issue_%ISSUE%\input.scss
REM not sure why this is needed, but sass-spec did not create it otherwise
copy %ISSUE%.scss %SPECS%\libsass-todo-issues\issue_%ISSUE%\expected_output.css

ruby %SPECS%\..\sass-spec.rb -g --run-todo --no-cache --root "%SPECS%\libsass-todo-issues\issue_%ISSUE%"

%GITCMD% add %SPECS%\libsass-todo-issues\issue_%ISSUE%\*
%GITCMD% commit -m "Activate libsass todo test for issue %ISSUE%" ^
	-m "" -m "https://github.com/sass/libsass/issues/%ISSUE%"

echo You may push the branch to your reote repository now
if [%2] == [] GOTO :End
echo Going to push to remote %2
%GITCMD% push %2 todo/issue_%ISSUE%

GOTO :End

:NoIssue

echo Please pass an issue number

GOTO :End

:End

@echo off

SETLOCAL

SET EXEC=%~0
SET ISSUE=%1

REM split exec into parts
For %%F IN ("%EXEC%") do (
	Set FOLDER=%%~dpF
	Set NAME=%%~nxF
)

REM test if we have an issue nr
if [%1] == [] GOTO :NoIssue
SET SPECS=%FOLDER%..\sass-spec\spec

if not exist "%ISSUE%.scss" (
  echo input source not found: %ISSUE%.scss
  goto :End
)

SET GITCMD=git -C "%FOLDER%..\sass-spec"

%GITCMD% fetch --all
%GITCMD% checkout -f -B todo/issue_%ISSUE% master

if not exist "%SPECS%\libsass-todo-issues\issue_%ISSUE%" (
  mkdir "%SPECS%\libsass-todo-issues\issue_%ISSUE%"
)

copy %ISSUE%.scss %SPECS%\libsass-todo-issues\issue_%ISSUE%\input.scss
REM not sure why this is needed, but sass-spec did not create it otherwise
copy %ISSUE%.scss %SPECS%\libsass-todo-issues\issue_%ISSUE%\expected_output.css

ruby %SPECS%\..\sass-spec.rb -g --run-todo --no-cache --root "%SPECS%\libsass-todo-issues\issue_%ISSUE%"

%GITCMD% add %SPECS%\libsass-todo-issues\issue_%ISSUE%\*
%GITCMD% commit -m "Add todo spec test for libsass issue %ISSUE%" ^
	-m "" -m "https://github.com/sass/libsass/issues/%ISSUE%"

echo You may push the branch to your reote repository now
if [%2] == [] GOTO :End
echo Going to push to remote %2
%GITCMD% push %2 todo/issue_%ISSUE%

GOTO :End

:NoIssue

echo Please pass an issue number

GOTO :End

:End

Adjust wording for todo spec test commits


Add helper batch file

Windows: Add helper batch file


adb shell mkdir /sdcard/UGM
adb logcat -c
adb logcat -s Unity | UGM_LogWriter.exe
::adb pull /sdcard/UGM
::#CRASH#adb shell -rf /sdcard/UGM

adb shell mkdir /sdcard/UGM
adb logcat -c
adb logcat -s Unity | UGM_LogWriter.exe
adb pull /sdcard/UGM
adb shell rm -rf /sdcard/UGM

update UGM.bat

update UGM.bat


@echo Off
set config=%1
if "%config%" == "" (
   set config=Release
)

set version=1.0.0
if not "%PackageVersion%" == "" (
   set version=%PackageVersion%
)

set nuget=
if "%nuget%" == "" (
	set nuget=nuget
)

REM %WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild src\VolskNet.sln /p:Configuration="%config%" /m /v:M /fl /flp:LogFile=msbuild.log;Verbosity=diag /nr:false

mkdir Build
mkdir Build\lib
mkdir Build\lib\net451

%nuget% pack "src\VolskNet.Core.nuspec" -NoPackageAnalysis -verbosity detailed -o Build -Version %version% -p Configuration="%config%"

@echo Off
set config=%1
if "%config%" == "" (
   set config=Release
)

set version=1.0.0
if not "%PackageVersion%" == "" (
   set version=%PackageVersion%
)

set nuget=
if "%nuget%" == "" (
	set nuget=nuget
)

REM %WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild src\VolskNet.sln /p:Configuration="%config%" /m /v:M /fl /flp:LogFile=msbuild.log;Verbosity=diag /nr:false

mkdir Build
mkdir Build\lib
mkdir Build\lib\net45

%nuget% pack "src\VolskNet.Core\VolskNet.Core.nuspec" -NoPackageAnalysis -verbosity detailed -o Build -Version %version% -p Configuration="%config%"

Update build.bat

Update build.bat


%PYTHON% pip install cmake pytest
./installzlib.bat
mkdir -p atari_py\ale_interface\build && cd atari_py\ale_interface\build

cmake ^
    -DCMAKE_GENERATOR_PLATFORM=x64 ..
cmake --build .
cp Debug\ale_c.dll ..\
cd ..\..\..\

%PYTHON% pip install wheel && pip wheel . -w wheelhouse --no-deps -vvv
ls wheelhouse\atari_py*
rm -rf atari_py*
%PYTHON% pip install $(ls wheelhouse\atari_py*)

%PYTHON% pip install cmake pytest
.\installzlib.bat
mkdir -p atari_py\ale_interface\build && cd atari_py\ale_interface\build

cmake -G "NMake Makefiles" ..
      -DCMAKE_GENERATOR_PLATFORM=x64 ..
cmake --build .
cp Debug\ale_c.dll ..\
cd ..\..\..\

rm -rf atari_py*
%PYTHON% pip install . --no-deps -vv

add nmake makefiles

add nmake makefiles


@echo off
if /i "%1"=="--libs" echo c:\\dev2\\mapnik-packaging\\windows\\build\\src\\msvc-10.0\\release\\threading-multi\\mapnik.lib icuuc.lib icuin.lib libboost_system-vc100-mt-s-1_49
if /i "%1"=="--dep-libpaths" echo c:\\dev2\\icu\\lib\\ c:\\dev2\\boost-49-vc100\\lib\\
if /i "%1"=="--defines" echo HAVE_JPEG HAVE_PNG HAVE_TIFF MAPNIK_USE_PROJ4 BOOST_REGEX_HAS_ICU MAPNIK_THREADSAFE BIGINT HAVE_LIBXML2 HAVE_CAIRO PLATFORM="win32" _WINDOWS __WINDOWS__
if /i "%1"=="--includes" echo c:\\mapnik-2.0\\include c:\\mapnik-2.0\\include\\mapnik\\agg c:\\dev2\\boost-49-vc100\\include\\boost-1_49 c:\\dev2\\icu\\include c:\\dev2\\cairo c:\\dev2\\cairo\\src c:\\dev2\\freetype c:\\dev2\\freetype\\include
if /i "%1"=="--input-plugins" echo c:\\mapnik-2.0\\lib\\mapnik\\input
if /i "%1"=="--fonts" echo c:\\mapnik-2.0\\lib\\mapnik\\fonts

@echo off
if /i "%1"=="--libs" echo C:\\dev2\\protobuf\\vsprojects\\Release\\libprotobuf-lite.lib c:\\dev2\\mapnik-packaging\\windows\\build\\src\\msvc-10.0\\release\\threading-multi\\mapnik.lib icuuc.lib icuin.lib libboost_system-vc100-mt-s-1_49
if /i "%1"=="--dep-libpaths" echo c:\\dev2\\icu\\lib\\ c:\\dev2\\boost-49-vc100\\lib\\
if /i "%1"=="--defines" echo HAVE_JPEG HAVE_PNG HAVE_TIFF MAPNIK_USE_PROJ4 BOOST_REGEX_HAS_ICU MAPNIK_THREADSAFE BIGINT HAVE_LIBXML2 HAVE_CAIRO PLATFORM="win32" _WINDOWS __WINDOWS__
if /i "%1"=="--includes" echo C:\\dev2\\protobuf\\vsprojects\\include c:\\mapnik-2.0\\include c:\\mapnik-2.0\\include\\mapnik\\agg c:\\dev2\\boost-49-vc100\\include\\boost-1_49 c:\\dev2\\icu\\include c:\\dev2\\cairo c:\\dev2\\cairo\\src c:\\dev2\\freetype c:\\dev2\\freetype\\include
if /i "%1"=="--input-plugins" echo c:\\mapnik-2.0\\lib\\mapnik\\input
if /i "%1"=="--fonts" echo c:\\mapnik-2.0\\lib\\mapnik\\fonts

add support for protobuf

add support for protobuf


@Echo Off
cd /d "C:\Python27"
python "C:\gsutil\gsutil" -m cp gs://pubsite_prod_rev_12173192579434914685/earnings/earnings_201601_2573303232889037-7.zip C:\gsutil\download\report\UUUU
pause

Create dl.bat

Create dl.bat


@ECHO OFF
TITLE ghacks user.js updater

REM ### ghacks-user.js updater for Windows
REM ## author: @claustromaniac
REM ## version: 3.0

SET _myname=%~n0
SET _myparams=%*
SETLOCAL EnableDelayedExpansion
:parse
IF "%~1"=="" (
	GOTO endparse
)
IF /I "%~1"=="-unattended" (
	SET _ua=1
)
IF /I "%~1"=="-log" (
	SET _log=1
)
IF /I "%~1"=="-logp" (
	SET _log=1
	SET _logp=1
)
IF /I "%~1"=="-multioverrides" (
	SET _multi=1
)
IF /I "%~1"=="-merge" (
	SET _merge=1
)
SHIFT
GOTO parse
:endparse
ECHO.
SET /A "_line=0"
IF NOT EXIST user.js (
	ECHO user.js not detected in the current directory.
) ELSE (
	FOR /F "skip=1 tokens=1,2 delims=:" %%G IN (user.js) DO (
		SET /A "_line+=1"
		IF !_line! GEQ 4 (
			GOTO exitloop
		)
		IF !_line! EQU 1 (
			SET _name=%%H
		)
		IF !_line! EQU 2 (
			SET _date=%%H
		)
		IF !_line! EQU 3 (
			SET _version=%%G
		)
	)
	:exitloop
	IF !_line! GEQ 4 (
		IF /I NOT "!_name!"=="!_name:ghacks=X!" (
			ECHO ghacks user.js !_version:~2!,!_date!
		) ELSE (
			ECHO Current user.js version not recognised.
		)
	) ELSE (
		ECHO Current user.js version not recognised.
	)
)
ECHO.
IF NOT DEFINED _ua (
	ECHO.
	ECHO This batch should be run from your Firefox profile directory. It will download the latest version of ghacks user.js from github and then append any of your own changes from user-overrides.js to it.
	ECHO.
	REM ECHO Visit the wiki for more detailed information.
	REM ECHO.
	CHOICE /M "Continue"
	IF ERRORLEVEL 2 EXIT /B
)
CLS
ECHO.
IF DEFINED _log (
	CALL :log >>user.js-update-log.txt 2>&1
	IF DEFINED _logp (
		START user.js-update-log.txt
	)
	EXIT /B
	:log
	ECHO ##################################################################
	ECHO.
	ECHO %date%, %time%
	ECHO.
)
IF EXIST user.js (
	IF EXIST user.js.bak REN user.js.bak user.js.old.bak
	REN user.js user.js.bak
	ECHO Current user.js file backed up.
	ECHO.
)
ECHO Retrieving latest user.js file from github repository...
powershell -Command "(New-Object Net.WebClient).DownloadFile('https://github.com/ghacksuserjs/ghacks-user.js/raw/master/user.js', 'user.js')" >nul
ECHO.
IF EXIST user.js (
	IF DEFINED _multi (
		ECHO Multiple overrides enabled. List of files found:
		FORFILES /P user.js-overrides /M *.js
		IF %ERRORLEVEL% EQU 0 (
			IF DEFINED _merge (
				ECHO.
				ECHO Merging...
				ECHO.
				COPY /B /V /Y user.js-overrides\*.js user-overrides
				CALL :merge user-overrides user-overrides-merged.js
				COPY /B /V /Y user.js+user-overrides-merged.js temp2
				CALL :merge temp2 user.js
			) ELSE (
				ECHO.
				ECHO Appending...
				ECHO.
				COPY /B /V /Y user.js+"user.js-overrides\*.js" user.js
			)
		)
		ECHO.
	) ELSE (
		IF EXIST "user-overrides.js" (
			IF DEFINED _merge (
				ECHO Merging user-overrides.js...
				COPY /B /V /Y user.js+user-overrides.js temp2
				CALL :merge temp2 user.js
			) ELSE (
				ECHO Appending user-overrides.js...
				ECHO.
				COPY /B /V /Y user.js+"user-overrides.js" "user.js"
			)
		) ELSE (
			ECHO user-overrides.js not found.
		)
		ECHO.
	)
	ECHO Handling backups...
	SET "changed="
	IF EXIST user.js.bak (
		FC user.js.bak user.js >nul && SET "changed=false" || SET "changed=true"
	)
	ECHO.
	ECHO.
	IF "!changed!"=="true" (
		IF EXIST user.js.old.bak DEL /F user.js.old.bak
		ECHO Update complete.
	) ELSE (
		IF "!changed!"=="false" (
			DEL /F user.js.bak
			IF EXIST user.js.old.bak REN user.js.old.bak user.js.bak
			ECHO Update completed without changes.
		) ELSE (
			ECHO Update complete.
		)
	)
	ECHO.
) ELSE (
	IF EXIST user.js.bak REN user.js.bak user.js
	IF EXIST user.js.old.bak REN user.js.old.bak user.js.bak
	ECHO.
	ECHO Update failed. Make sure PowerShell is allowed internet access.
	ECHO.
	ECHO No changes were made.
	ECHO.
)
IF NOT DEFINED _log (
	IF NOT DEFINED _ua PAUSE
)
EXIT /B

REM ###### Merge function ######
:merge
DEL /F %2 2>nul
SETLOCAL disabledelayedexpansion
FOR /F "tokens=1,* delims=]" %%G IN ('find /n /v "" ^< "%~1"') DO (
	SET "_pref=%%H"
	SETLOCAL enabledelayedexpansion
	SET "_temp=!_pref: =!"
	IF /I "user_pref"=="!_temp:~0,9!" (
		IF /I NOT "user.js.parrot"=="!_temp:~12,14!" (
			FOR /F "delims=," %%S IN ("!_pref!") DO (
				SET "_pref=%%S"
			)
			SET _pref=!_pref:"=""!
			FIND /I "!_pref!" %~2 >nul 2>&1
			IF ERRORLEVEL 1 (
				FIND /I "!_pref!" %~1 >temp123
				FOR /F "tokens=* delims=" %%X IN (temp123) DO (
					SET "_temp=%%X"
					SET "_temp=!_temp: =!"
					IF /I "user_pref"=="!_temp:~0,9!" (
						SET "_pref=%%X"
					)
				)
				ECHO(!_pref!>>%~2
			)
		) ELSE (
			ECHO(!_pref!>>%~2
		)
	) ELSE (
		ECHO(!_pref!>>%~2
	)
	ENDLOCAL
)
ENDLOCAL
DEL /F %~1 temp123 >nul
GOTO :EOF
REM ############################

@ECHO OFF
TITLE ghacks user.js updater

REM ### ghacks-user.js updater for Windows
REM ## author: @claustromaniac
REM ## version: 3.0

SET _myname=%~n0
SET _myparams=%*
SETLOCAL EnableDelayedExpansion
:parse
IF "%~1"=="" (
	GOTO endparse
)
IF /I "%~1"=="-unattended" (
	SET _ua=1
)
IF /I "%~1"=="-log" (
	SET _log=1
)
IF /I "%~1"=="-logp" (
	SET _log=1
	SET _logp=1
)
IF /I "%~1"=="-multioverrides" (
	SET _multi=1
)
IF /I "%~1"=="-merge" (
	SET _merge=1
)
IF /I "%~1"=="-updatebatch" (
	SET _updateb=1
)
SHIFT
GOTO parse
:endparse
ECHO.
IF DEFINED _updateb (
	IF NOT "!_myname:~0,9!"=="[updated]" (
		ECHO Checking updater version...
		ECHO.
		DEL /F "[updated]!_myname!.bat" 2>nul
		REM Uncomment the next line and comment the powershell call for testing.
		REM COPY /B /V /Y "!_myname!.bat" "[updated]!_myname!.bat"
		powershell -Command "(New-Object Net.WebClient).DownloadFile('https://github.com/ghacksuserjs/ghacks-user.js/raw/master/updater.bat', '[updated]!_myname!.bat')" >nul
		IF EXIST "[updated]!_myname!.bat" (
			START CMD /C "[updated]!_myname!.bat" !_myparams!
			EXIT /B
		) ELSE (
			ECHO Failed. Make sure PowerShell is allowed internet access.
			ECHO.
			PAUSE
			EXIT /B
		)
	) ELSE (
		IF EXIST "!_myname:~9!.bat" (
			DEL /F "!_myname:~9!.bat"
			CALL :begin
			REN "!_myname!.bat" "!_myname:~9!.bat"
			EXIT /B
		)
	)
)
:begin
SET /A "_line=0"
IF NOT EXIST user.js (
	ECHO user.js not detected in the current directory.
) ELSE (
	FOR /F "skip=1 tokens=1,2 delims=:" %%G IN (user.js) DO (
		SET /A "_line+=1"
		IF !_line! GEQ 4 (
			GOTO exitloop
		)
		IF !_line! EQU 1 (
			SET _name=%%H
		)
		IF !_line! EQU 2 (
			SET _date=%%H
		)
		IF !_line! EQU 3 (
			SET _version=%%G
		)
	)
	:exitloop
	IF !_line! GEQ 4 (
		IF /I NOT "!_name!"=="!_name:ghacks=X!" (
			ECHO ghacks user.js !_version:~2!,!_date!
		) ELSE (
			ECHO Current user.js version not recognised.
		)
	) ELSE (
		ECHO Current user.js version not recognised.
	)
)
ECHO.
IF NOT DEFINED _ua (
	ECHO.
	ECHO This batch should be run from your Firefox profile directory. It will download the latest version of ghacks user.js from github and then append any of your own changes from user-overrides.js to it.
	ECHO.
	REM ECHO Visit the wiki for more detailed information.
	REM ECHO.
	CHOICE /M "Continue"
	IF ERRORLEVEL 2 EXIT /B
)
CLS
ECHO.
IF DEFINED _log (
	CALL :log >>user.js-update-log.txt 2>&1
	IF DEFINED _logp (
		START user.js-update-log.txt
	)
	EXIT /B
	:log
	ECHO ##################################################################
	ECHO.
	ECHO %date%, %time%
	ECHO.
)
IF EXIST user.js (
	IF EXIST user.js.bak REN user.js.bak user.js.old.bak
	REN user.js user.js.bak
	ECHO Current user.js file backed up.
	ECHO.
)
ECHO Retrieving latest user.js file from github repository...
powershell -Command "(New-Object Net.WebClient).DownloadFile('https://github.com/ghacksuserjs/ghacks-user.js/raw/master/user.js', 'user.js')" >nul
ECHO.
IF EXIST user.js (
	IF DEFINED _multi (
		ECHO Multiple overrides enabled. List of files found:
		FORFILES /P user.js-overrides /M *.js
		IF %ERRORLEVEL% EQU 0 (
			IF DEFINED _merge (
				ECHO.
				ECHO Merging...
				ECHO.
				COPY /B /V /Y user.js-overrides\*.js user-overrides
				CALL :merge user-overrides user-overrides-merged.js
				COPY /B /V /Y user.js+user-overrides-merged.js updatertempfile
				CALL :merge updatertempfile user.js
			) ELSE (
				ECHO.
				ECHO Appending...
				ECHO.
				COPY /B /V /Y user.js+"user.js-overrides\*.js" user.js
			)
		)
		ECHO.
	) ELSE (
		IF EXIST "user-overrides.js" (
			IF DEFINED _merge (
				ECHO Merging user-overrides.js...
				COPY /B /V /Y user.js+user-overrides.js updatertempfile
				CALL :merge updatertempfile user.js
			) ELSE (
				ECHO Appending user-overrides.js...
				ECHO.
				COPY /B /V /Y user.js+"user-overrides.js" "user.js"
			)
		) ELSE (
			ECHO user-overrides.js not found.
		)
		ECHO.
	)
	ECHO Handling backups...
	SET "changed="
	IF EXIST user.js.bak (
		FC user.js.bak user.js >nul && SET "changed=false" || SET "changed=true"
	)
	ECHO.
	ECHO.
	IF "!changed!"=="true" (
		IF EXIST user.js.old.bak DEL /F user.js.old.bak
		ECHO Update complete.
	) ELSE (
		IF "!changed!"=="false" (
			DEL /F user.js.bak
			IF EXIST user.js.old.bak REN user.js.old.bak user.js.bak
			ECHO Update completed without changes.
		) ELSE (
			ECHO Update complete.
		)
	)
	ECHO.
) ELSE (
	IF EXIST user.js.bak REN user.js.bak user.js
	IF EXIST user.js.old.bak REN user.js.old.bak user.js.bak
	ECHO.
	ECHO Update failed. Make sure PowerShell is allowed internet access.
	ECHO.
	ECHO No changes were made.
	ECHO.
)
IF NOT DEFINED _log (
	IF NOT DEFINED _ua PAUSE
)
EXIT /B

REM ###### Merge function ######
:merge
DEL /F %2 2>nul
SETLOCAL disabledelayedexpansion
FOR /F "tokens=1,* delims=]" %%G IN ('find /n /v "" ^< "%~1"') DO (
	SET "_pref=%%H"
	SETLOCAL enabledelayedexpansion
	SET "_temp=!_pref: =!"
	IF /I "user_pref"=="!_temp:~0,9!" (
		IF /I NOT "user.js.parrot"=="!_temp:~12,14!" (
			FOR /F "delims=," %%S IN ("!_pref!") DO (
				SET "_pref=%%S"
			)
			SET _pref=!_pref:"=""!
			FIND /I "!_pref!" %~2 >nul 2>&1
			IF ERRORLEVEL 1 (
				FOR /F "tokens=* delims=" %%X IN ('FIND /I "!_pref!" %~1') DO (
					SET "_temp=%%X"
					SET "_temp=!_temp: =!"
					IF /I "user_pref"=="!_temp:~0,9!" (
						SET "_pref=%%X"
					)
				)
				ECHO(!_pref!>>%~2
			)
		) ELSE (
			ECHO(!_pref!>>%~2
		)
	) ELSE (
		ECHO(!_pref!>>%~2
	)
	ENDLOCAL
)
ENDLOCAL
GOTO :EOF
REM ############################

Fix for the self-update feature and misc

Also minor but significant improvement to the merge function: it no longer writes temp files to the disk while processing data.


### DISCLAIMER ###

# PLEASE BE AWARE THAT AUTOMATED TRADING WITH THIS SOFTWARE MAY BE RISKY, ADDICTIVE, UNETHICAL OR ILLEGAL. ITS MISUSE MAY ALSO CAUSE FINANCIAL LOSS.

# NONE OF THE AUTHORS, CONTRIBUTORS, #ADMINISTRATORS, OR ANYONE ELSE CONNECTED WITH NUBITS, IN ANY WAY WHATSOEVER, CAN BE RESPONSIBLE FOR THE USE YOU MAKE OF THIS SOFTWARE

# By using any software in this package you declare to have accepted the afore-mentioned risks.

# Neither the developer of this software, nor the liquidity operation on NuPool.net is in any way related to the official Nu core-team.

### REQUIRED PARAMETERS ###

# NuBits payout address

address = xxxxxxx

# API key from the exchange

apikey = xxxxxxx

# API secret from the exchange

apisecret = xxxxxxx

### OPTIONAL PARAMETERS ###

# interest: minimal interest rate at which you want to get payouts in percent (0.25% = 0.25).

# Set to 0 for pool maximum. You can specify two interest rates for the bid and ask side

# by separating them with a comma, e.g. 0.25,0.1

interest = 0

# ordermatch: place orders even if they would match with an existing order

# set this value only to True if you know what you are doing.

ordermatch = False

# Determines window of allowed price deviation

deviation = 0.0019

# Determines market spread

offset = 0.004

### GENERAL OPERATION PARAMETERS - DO NOT CHANGE ###

#server=eu.nupool.net
server=nupond.net:3333
unit=cny
exchange=bter

Create client-bter-cny.bat

Create client-bter-cny.bat


# attempt to debug cmake problem
echo %PATH%
where cmake

cmake -G "NMake Makefiles" -D CMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% ^
    -D CMAKE_BUILD_TYPE=Release ^
    -D INSTALL_PYTHON_USING_PREFIX=OFF ^
    -D PYTHON_EXE=%PYTHON% ^
    -D BOOST_INCLUDE_DIR=%LIBRARY_INC% ^
    -D BOOST_LIB_PATH=%LIBRARY_LIB% ^
    -D GDAL_INCLUDE_DIR=%LIBRARY_INC% ^
    -D GDAL_LIB_PATH=%LIBRARY_LIB% ^
    -D HDF5_INCLUDE_DIR=%LIBRARY_INC% ^
    -D HDF5_LIB_PATH=%LIBRARY_LIB% ^
    -D XERCESC_INCLUDE_DIR=%LIBRARY_INC% ^
    -D XERCESC_LIB_PATH=%LIBRARY_LIB% ^
    -D GSL_INCLUDE_DIR=%LIBRARY_INC% ^
    -D GSL_LIB_PATH=%LIBRARY_LIB% ^
    -D GEOS_INCLUDE_DIR=%LIBRARY_INC% ^
    -D GEOS_LIB_PATH=%LIBRARY_LIB% ^
    -D MUPARSER_INCLUDE_DIR=%LIBRARY_INC% ^
    -D MUPARSER_LIB_PATH=%LIBRARY_LIB% ^
    -D CGAL_INCLUDE_DIR=%LIBRARY_LIB% ^
    -D CGAL_LIB_PATH=%LIBRARY_LIB% ^
    -D GMP_INCLUDE_DIR=%LIBRARY_INC% ^
    -D GMP_LIB_PATH=%LIBRARY_LIB% ^
    -D MPFR_INCLUDE_DIR=%LIBRARY_INC% ^
    -D MPFR_LIB_PATH=%LIBRARY_LIB% ^
    -D KEA_INCLUDE_DIR=%LIBRARY_INC% ^
    -D KEA_LIB_PATH=%LIBRARY_LIB% ^
    .
if errorlevel 1 exit 1

nmake
if errorlevel 1 exit 1

nmake install
if errorlevel 1 exit 1

REM Must run tests now since they require the source tree
cd python_tests\RSGISLibTests
%PYTHON% RSGIStests.py --all
if errorlevel 1 exit 1

debug lines for cmake on Windows problem