Browse Source

Cleanup

Former-commit-id: 30c7d35bcd8a02856af0c0d2a0e7d740dd4fcf14
Former-commit-id: a29689af60105bc7bd421e027a1e4eece49a6a79
Former-commit-id: 93ec7f3b6ef3abf3b89c2b680ad1be16d613f333
pull/17/head
James Jackson-South 11 years ago
parent
commit
f93da87f59
  1. 6
      .nuget/NuGet.Config
  2. 1
      .nuget/NuGet.exe.REMOVED.git-id
  3. 144
      .nuget/NuGet.targets
  4. 4
      .nuget/packages.config
  5. 12
      ImageProcessor.sln
  6. 49
      old/.gitattributes
  7. 173
      old/.gitignore
  8. 13
      old/APACHE-2.0-LICENSE.txt
  9. 49
      old/README.md
  10. 61
      old/appveyor.yml
  11. 5
      old/build/Build.bat
  12. 1
      old/build/Doxyfile.REMOVED.git-id
  13. 85
      old/build/ImageProcessorDoc.shfbproj
  14. 31
      old/build/NuSpecs/ImageProcessor.Plugins.Cair.nuspec
  15. 32
      old/build/NuSpecs/ImageProcessor.Plugins.WebP.nuspec
  16. 35
      old/build/NuSpecs/ImageProcessor.Web.Config.nuspec
  17. 41
      old/build/NuSpecs/ImageProcessor.Web.Plugins.AzureBlobCache.nuspec
  18. 32
      old/build/NuSpecs/ImageProcessor.Web.PostProcessor.nuspec
  19. 34
      old/build/NuSpecs/ImageProcessor.Web.nuspec
  20. 29
      old/build/NuSpecs/ImageProcessor.nuspec
  21. 244
      old/build/build.ps1
  22. 74
      old/build/build.xml
  23. 9
      old/build/content/ImageProcessor.Plugins.WebP/web.config.transform
  24. 16
      old/build/content/ImageProcessor.Web.Config/web.config.transform
  25. 14
      old/build/content/ImageProcessor.Web.Plugins.AzureBlobCache/config/imageprocessor/cache.config.transform
  26. 14
      old/build/content/ImageProcessor.Web/web.config.transform
  27. 5
      old/build/coverage.bat
  28. 847
      old/build/psake.psm1
  29. 1
      old/build/tools/NUnitHTMLReportGenerator.exe.REMOVED.git-id
  30. 7
      old/build/tools/NUnitHTMLReportGenerator.exe.config
  31. BIN
      old/build/tools/docu/Interop.SparkLanguagePackageLib.dll
  32. 1
      old/build/tools/docu/Spark.dll.REMOVED.git-id
  33. BIN
      old/build/tools/docu/SparkLanguage.dll
  34. 1
      old/build/tools/docu/StructureMap.dll.REMOVED.git-id
  35. 1
      old/build/tools/docu/docu.exe.REMOVED.git-id
  36. 3
      old/build/tools/docu/docu.exe.config
  37. 82
      old/build/tools/docu/templates/!namespace/!type.htm.spark
  38. 1
      old/build/tools/docu/templates/!namespace/_comment.spark
  39. 12
      old/build/tools/docu/templates/!namespace/_events.spark
  40. 4
      old/build/tools/docu/templates/!namespace/_example.spark
  41. 19
      old/build/tools/docu/templates/!namespace/_fields.spark
  42. 46
      old/build/tools/docu/templates/!namespace/_methods.spark
  43. 14
      old/build/tools/docu/templates/!namespace/_namespaces.spark
  44. 27
      old/build/tools/docu/templates/!namespace/_properties.spark
  45. 3
      old/build/tools/docu/templates/!namespace/_remarks.spark
  46. 14
      old/build/tools/docu/templates/!namespace/_types.spark
  47. 3
      old/build/tools/docu/templates/!namespace/_value.spark
  48. 49
      old/build/tools/docu/templates/!namespace/index.htm.spark
  49. 6
      old/build/tools/docu/templates/_common_footer.spark
  50. 8
      old/build/tools/docu/templates/_namespaces.spark
  51. 10
      old/build/tools/docu/templates/_types.spark
  52. 23
      old/build/tools/docu/templates/index.htm.spark
  53. 21
      old/build/tools/docu/templates/js/example.js
  54. 19
      old/build/tools/docu/templates/js/jquery-1.3.2.min.js
  55. 11
      old/build/tools/docu/templates/js/jquery.scrollTo-min.js
  56. 11
      old/build/tools/docu/templates/js/navigation.js
  57. 263
      old/build/tools/docu/templates/main.css
  58. 1
      old/build/tools/doxygen/doxygen.exe.REMOVED.git-id
  59. 1
      old/build/tools/doxygen/doxyindexer.exe.REMOVED.git-id
  60. 1
      old/build/tools/doxygen/doxysearch.cgi.REMOVED.git-id
  61. 6
      old/src/.nuget/NuGet.Config
  62. 1
      old/src/.nuget/NuGet.exe.REMOVED.git-id
  63. 136
      old/src/.nuget/NuGet.targets
  64. 7
      old/src/.nuget/packages.config
  65. 6
      old/src/ImageProcessor.Playground/App.config
  66. 87
      old/src/ImageProcessor.Playground/ImageProcessor.Playground.csproj
  67. 186
      old/src/ImageProcessor.Playground/Program.cs
  68. 36
      old/src/ImageProcessor.Playground/Properties/AssemblyInfo.cs
  69. BIN
      old/src/ImageProcessor.Playground/images/input/000.png
  70. BIN
      old/src/ImageProcessor.Playground/images/input/001.png
  71. 1
      old/src/ImageProcessor.Playground/images/input/120430.gif.REMOVED.git-id
  72. 1
      old/src/ImageProcessor.Playground/images/input/1aaa.jpg.REMOVED.git-id
  73. 1
      old/src/ImageProcessor.Playground/images/input/2006-citybus.jpg.REMOVED.git-id
  74. 1
      old/src/ImageProcessor.Playground/images/input/2008.jpg.REMOVED.git-id
  75. 1
      old/src/ImageProcessor.Playground/images/input/2012-citybus.jpg.REMOVED.git-id
  76. BIN
      old/src/ImageProcessor.Playground/images/input/4.sm.webp
  77. 1
      old/src/ImageProcessor.Playground/images/input/Arc-de-Triomphe-France.jpg.REMOVED.git-id
  78. 1
      old/src/ImageProcessor.Playground/images/input/Bikesgray.png.REMOVED.git-id
  79. 1
      old/src/ImageProcessor.Playground/images/input/Calliphora_sp_Portrait.jpg.REMOVED.git-id
  80. 1
      old/src/ImageProcessor.Playground/images/input/IC580196.jpg.REMOVED.git-id
  81. 1
      old/src/ImageProcessor.Playground/images/input/Martin-Schoeller-Jack-Nicholson-Portrait.jpeg.REMOVED.git-id
  82. BIN
      old/src/ImageProcessor.Playground/images/input/PIA11667_modest.jpg
  83. 1
      old/src/ImageProcessor.Playground/images/input/Tl4Yb.gif.REMOVED.git-id
  84. BIN
      old/src/ImageProcessor.Playground/images/input/Turtle.jpg
  85. 1
      old/src/ImageProcessor.Playground/images/input/Valve_original_(1).PNG.REMOVED.git-id
  86. 1
      old/src/ImageProcessor.Playground/images/input/arc_de_triomphe_paris_france.jpg.REMOVED.git-id
  87. BIN
      old/src/ImageProcessor.Playground/images/input/blue-balloon.jpg
  88. BIN
      old/src/ImageProcessor.Playground/images/input/blur-test.jpg
  89. BIN
      old/src/ImageProcessor.Playground/images/input/blur-test.png
  90. 1
      old/src/ImageProcessor.Playground/images/input/bob_revolutionpro_wilderness_02_2013_72dpi_2000x2000.jpg.REMOVED.git-id
  91. 1
      old/src/ImageProcessor.Playground/images/input/cat.jpg.REMOVED.git-id
  92. BIN
      old/src/ImageProcessor.Playground/images/input/ce1a34f6-52bd-11e4-8164-54281a6247c9.jpg
  93. BIN
      old/src/ImageProcessor.Playground/images/input/circle.png
  94. BIN
      old/src/ImageProcessor.Playground/images/input/circle2.png
  95. BIN
      old/src/ImageProcessor.Playground/images/input/circle3.png
  96. 1
      old/src/ImageProcessor.Playground/images/input/cmyk-test.png.REMOVED.git-id
  97. BIN
      old/src/ImageProcessor.Playground/images/input/cmyk.png
  98. 1
      old/src/ImageProcessor.Playground/images/input/cow_PNG2140.png.REMOVED.git-id
  99. BIN
      old/src/ImageProcessor.Playground/images/input/crop-base-300x200.jpg
  100. 1
      old/src/ImageProcessor.Playground/images/input/earth_lights_4800.tif.REMOVED.git-id

6
.nuget/NuGet.Config

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<solution>
<add key="disableSourceControlIntegration" value="true" />
</solution>
</configuration>

1
.nuget/NuGet.exe.REMOVED.git-id

@ -1 +0,0 @@
9ca66594f912a1fe7aec510819006fb1a80bc1a9

144
.nuget/NuGet.targets

@ -1,144 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">$(MSBuildProjectDirectory)\..\</SolutionDir>
<!-- Enable the restore command to run before builds -->
<RestorePackages Condition=" '$(RestorePackages)' == '' ">false</RestorePackages>
<!-- Property that enables building a package from a project -->
<BuildPackage Condition=" '$(BuildPackage)' == '' ">false</BuildPackage>
<!-- Determines if package restore consent is required to restore packages -->
<RequireRestoreConsent Condition=" '$(RequireRestoreConsent)' != 'false' ">true</RequireRestoreConsent>
<!-- Download NuGet.exe if it does not already exist -->
<DownloadNuGetExe Condition=" '$(DownloadNuGetExe)' == '' ">false</DownloadNuGetExe>
</PropertyGroup>
<ItemGroup Condition=" '$(PackageSources)' == '' ">
<!-- Package sources used to restore packages. By default, registered sources under %APPDATA%\NuGet\NuGet.Config will be used -->
<!-- The official NuGet package source (https://www.nuget.org/api/v2/) will be excluded if package sources are specified and it does not appear in the list -->
<!--
<PackageSource Include="https://www.nuget.org/api/v2/" />
<PackageSource Include="https://my-nuget-source/nuget/" />
-->
</ItemGroup>
<PropertyGroup Condition=" '$(OS)' == 'Windows_NT'">
<!-- Windows specific commands -->
<NuGetToolsPath>$([System.IO.Path]::Combine($(SolutionDir), ".nuget"))</NuGetToolsPath>
</PropertyGroup>
<PropertyGroup Condition=" '$(OS)' != 'Windows_NT'">
<!-- We need to launch nuget.exe with the mono command if we're not on windows -->
<NuGetToolsPath>$(SolutionDir).nuget</NuGetToolsPath>
</PropertyGroup>
<PropertyGroup>
<PackagesProjectConfig Condition=" '$(OS)' == 'Windows_NT'">$(MSBuildProjectDirectory)\packages.$(MSBuildProjectName.Replace(' ', '_')).config</PackagesProjectConfig>
<PackagesProjectConfig Condition=" '$(OS)' != 'Windows_NT'">$(MSBuildProjectDirectory)\packages.$(MSBuildProjectName).config</PackagesProjectConfig>
</PropertyGroup>
<PropertyGroup>
<PackagesConfig Condition="Exists('$(MSBuildProjectDirectory)\packages.config')">$(MSBuildProjectDirectory)\packages.config</PackagesConfig>
<PackagesConfig Condition="Exists('$(PackagesProjectConfig)')">$(PackagesProjectConfig)</PackagesConfig>
</PropertyGroup>
<PropertyGroup>
<!-- NuGet command -->
<NuGetExePath Condition=" '$(NuGetExePath)' == '' ">$(NuGetToolsPath)\NuGet.exe</NuGetExePath>
<PackageSources Condition=" $(PackageSources) == '' ">@(PackageSource)</PackageSources>
<NuGetCommand Condition=" '$(OS)' == 'Windows_NT'">"$(NuGetExePath)"</NuGetCommand>
<NuGetCommand Condition=" '$(OS)' != 'Windows_NT' ">mono --runtime=v4.0.30319 "$(NuGetExePath)"</NuGetCommand>
<PackageOutputDir Condition="$(PackageOutputDir) == ''">$(TargetDir.Trim('\\'))</PackageOutputDir>
<RequireConsentSwitch Condition=" $(RequireRestoreConsent) == 'true' ">-RequireConsent</RequireConsentSwitch>
<NonInteractiveSwitch Condition=" '$(VisualStudioVersion)' != '' AND '$(OS)' == 'Windows_NT' ">-NonInteractive</NonInteractiveSwitch>
<PaddedSolutionDir Condition=" '$(OS)' == 'Windows_NT'">"$(SolutionDir) "</PaddedSolutionDir>
<PaddedSolutionDir Condition=" '$(OS)' != 'Windows_NT' ">"$(SolutionDir)"</PaddedSolutionDir>
<!-- Commands -->
<RestoreCommand>$(NuGetCommand) install "$(PackagesConfig)" -source "$(PackageSources)" $(NonInteractiveSwitch) $(RequireConsentSwitch) -solutionDir $(PaddedSolutionDir)</RestoreCommand>
<BuildCommand>$(NuGetCommand) pack "$(ProjectPath)" -Properties "Configuration=$(Configuration);Platform=$(Platform)" $(NonInteractiveSwitch) -OutputDirectory "$(PackageOutputDir)" -symbols</BuildCommand>
<!-- We need to ensure packages are restored prior to assembly resolve -->
<BuildDependsOn Condition="$(RestorePackages) == 'true'">
RestorePackages;
$(BuildDependsOn);
</BuildDependsOn>
<!-- Make the build depend on restore packages -->
<BuildDependsOn Condition="$(BuildPackage) == 'true'">
$(BuildDependsOn);
BuildPackage;
</BuildDependsOn>
</PropertyGroup>
<Target Name="CheckPrerequisites">
<!-- Raise an error if we're unable to locate nuget.exe -->
<Error Condition="'$(DownloadNuGetExe)' != 'true' AND !Exists('$(NuGetExePath)')" Text="Unable to locate '$(NuGetExePath)'" />
<!--
Take advantage of MsBuild's build dependency tracking to make sure that we only ever download nuget.exe once.
This effectively acts as a lock that makes sure that the download operation will only happen once and all
parallel builds will have to wait for it to complete.
-->
<MsBuild Targets="_DownloadNuGet" Projects="$(MSBuildThisFileFullPath)" Properties="Configuration=NOT_IMPORTANT;DownloadNuGetExe=$(DownloadNuGetExe)" />
</Target>
<Target Name="_DownloadNuGet">
<DownloadNuGet OutputFilename="$(NuGetExePath)" Condition=" '$(DownloadNuGetExe)' == 'true' AND !Exists('$(NuGetExePath)')" />
</Target>
<Target Name="RestorePackages" DependsOnTargets="CheckPrerequisites">
<Exec Command="$(RestoreCommand)"
Condition="'$(OS)' != 'Windows_NT' And Exists('$(PackagesConfig)')" />
<Exec Command="$(RestoreCommand)"
LogStandardErrorAsError="true"
Condition="'$(OS)' == 'Windows_NT' And Exists('$(PackagesConfig)')" />
</Target>
<Target Name="BuildPackage" DependsOnTargets="CheckPrerequisites">
<Exec Command="$(BuildCommand)"
Condition=" '$(OS)' != 'Windows_NT' " />
<Exec Command="$(BuildCommand)"
LogStandardErrorAsError="true"
Condition=" '$(OS)' == 'Windows_NT' " />
</Target>
<UsingTask TaskName="DownloadNuGet" TaskFactory="CodeTaskFactory" AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll">
<ParameterGroup>
<OutputFilename ParameterType="System.String" Required="true" />
</ParameterGroup>
<Task>
<Reference Include="System.Core" />
<Using Namespace="System" />
<Using Namespace="System.IO" />
<Using Namespace="System.Net" />
<Using Namespace="Microsoft.Build.Framework" />
<Using Namespace="Microsoft.Build.Utilities" />
<Code Type="Fragment" Language="cs">
<![CDATA[
try {
OutputFilename = Path.GetFullPath(OutputFilename);
Log.LogMessage("Downloading latest version of NuGet.exe...");
WebClient webClient = new WebClient();
webClient.DownloadFile("https://www.nuget.org/nuget.exe", OutputFilename);
return true;
}
catch (Exception ex) {
Log.LogErrorFromException(ex);
return false;
}
]]>
</Code>
</Task>
</UsingTask>
</Project>

4
.nuget/packages.config

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="xunit.runner.console" version="2.0.0" />
</packages>

12
ImageProcessor.sln

@ -1,20 +1,12 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
VisualStudioVersion = 12.0.31101.0
# Visual Studio 14
VisualStudioVersion = 14.0.23107.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor", "src\ImageProcessor\ImageProcessor.csproj", "{8047C4AC-7097-4DE4-B00D-6D55EBCF1D36}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor.Tests", "tests\ImageProcessor.Tests\ImageProcessor.Tests.csproj", "{1741DC66-5404-4B15-AE58-B7721F1568A4}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{3D5BCCE2-A7EB-4453-9A86-A9C55CCFDCDF}"
ProjectSection(SolutionItems) = preProject
.nuget\NuGet.Config = .nuget\NuGet.Config
.nuget\NuGet.exe = .nuget\NuGet.exe
.nuget\NuGet.targets = .nuget\NuGet.targets
.nuget\packages.config = .nuget\packages.config
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU

49
old/.gitattributes

@ -1,49 +0,0 @@
*.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
*.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 merge=union
*.vbproj text=auto merge=union
*.fsproj text=auto merge=union
*.dbproj text=auto merge=union
*.sln text=auto eol=crlf merge=union

173
old/.gitignore

@ -1,173 +0,0 @@
#################
## Eclipse
#################
*.pydevproject
.project
.metadata
bin/**
tmp/**
tmp/**/*
*.tmp
*.bak
*.swp
*~.nib
local.properties
.classpath
.settings/
.loadpath
# External tool builders
.externalToolBuilders/
# Locally stored "Eclipse launch configurations"
*.launch
# CDT-specific
.cproject
# PDT-specific
.buildpath
#################
## Visual Studio
#################
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
# User-specific files
*.suo
*.user
*.sln.docstates
# Build results
**/[Dd]ebug/
**/[Rr]elease/
*_i.c
*_p.c
*.ilk
*.meta
*.obj
*.pch
*.pdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.vspscc
.builds
**/*.dotCover
# Xamarin
*.userprefs
## TODO: If you have NuGet Package Restore enabled, uncomment this
packages/
# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opensdf
*.sdf
# Visual Studio profiler
*.psess
*.vsp
# ReSharper is a .NET coding add-in
_ReSharper*
# Installshield output folder
[Ee]xpress
# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html
# Click-Once directory
publish
# Others
[Bb]in
[Oo]bj
sql
TestResults
*.Cache
ClientBin
stylecop.*
~$*
*.dbmdl
Generated_Code #added for RIA/Silverlight projects
# Backup & report files from converting an old project file to a newer
# Visual Studio version. Backup files are not needed, because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
############
## Windows
############
# Windows image file caches
Thumbs.db
# Folder config file
Desktop.ini
#############
## Python
#############
*.py[co]
# Packages
*.egg
*.egg-info
dist
eggs
parts
bin
var
sdist
develop-eggs
.installed.cfg
# Installer logs
pip-log.txt
# Unit test / coverage reports
.coverage
.tox
#Translations
*.mo
#Mr Developer
.mr.developer.cfg
# Mac crap
.DS_Store
build/_BuildOutput/
build/*.nupkg
build/TestResult.xml
*.db
_site/

13
old/APACHE-2.0-LICENSE.txt

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

49
old/README.md

@ -1,49 +0,0 @@
# ImageProcessor
### Build Status
|Branch | |
|:--------|:--------|
|**Debug**|[![Build status](https://ci.appveyor.com/api/projects/status/8ypr7527dnao04yr?svg=true)](https://ci.appveyor.com/project/JamesSouth/imageprocessor)|
|**Release**|[![Build status](https://ci.appveyor.com/api/projects/status/8ypr7527dnao04yr/branch/Master?svg=true)](https://ci.appveyor.com/project/JamesSouth/imageprocessor/branch/Master)|
|**Coverage Report**|[![Coverage Status](https://coveralls.io/repos/JimBobSquarePants/ImageProcessor/badge.svg)](https://coveralls.io/r/JimBobSquarePants/ImageProcessor?branch=V2)|
### Latest Releases
|Library |Version |Downloads |
|:-----------------|:-----------------|:-----------------|
|**ImageProcessor**|[![Nuget count](http://img.shields.io/nuget/v/ImageProcessor.svg)](https://www.nuget.org/packages/ImageProcessor/)|[![Nuget downloads](http://img.shields.io/nuget/dt/ImageProcessor.svg)](https://www.nuget.org/packages/ImageProcessor/)|
|**ImageProcessor.Web**|[![Nuget count](http://img.shields.io/nuget/v/ImageProcessor.Web.svg)](https://www.nuget.org/packages/ImageProcessor.Web/)|[![Nuget downloads](http://img.shields.io/nuget/dt/ImageProcessor.Web.svg)](https://www.nuget.org/packages/ImageProcessor.Web/)|
[![Issues open](http://img.shields.io/github/issues-raw/JimBobSquarePants/imageprocessor.svg)](https://huboard.com/JimBobSquarePants/ImageProcessor/)
[![Source Browser](https://img.shields.io/badge/Browse-Source-green.svg)](http://sourcebrowser.io/Browse/JimBobSquarePants/ImageProcessor/)
[![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/JimBobSquarePants/ImageProcessor?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
Imageprocessor is a lightweight, extensible library written in C# that allows you to manipulate images on-the-fly using .NET 4.5+
It's fast, extensible, easy to use, comes bundled with some great features and is fully open source.
For full documentation please see [http://imageprocessor.org/](http://imageprocessor.org/)
## Contributing to ImageProcessor
Contribution is most welcome! I mean, that's what this is all about isn't it?
Things I would :heart: people to help me out with:
- Unit tests. I need to get some going for all the regular expressions within the ImageProcessor core plus anywhere else we can think of. If that's your bag please contribute.
- Documentation. Nobody likes doing docs, I've written a lot but my prose is clumsy and verbose. If you think you can make things clearer or you spot any mistakes please submit a pull request (Guide to how the docs work below).
**Just remember to StyleCop all things! :oncoming_police_car:**
## RoadMap
I want the next version of ImageProcessor to run on all devices. Sadly it looks like using `System.Drawing` will not allow me to do that so I need to have a look at using an alternative. This is a lot of work so any help that could be offered would be greatly appreciated.
## Documentation
ImageProcessor's documentation, included in this repo in the gh-pages branch, is built with [Jekyll](http://jekyllrb.com) and publicly hosted on GitHub Pages at <http://imageprocessor.org>. The docs may also be run locally.
### Running documentation locally
1. If necessary, [install Jekyll](http://jekyllrb.com/docs/installation) (requires v2.2.x).
- **Windows users:** Read [this unofficial guide](https://github.com/juthilo/run-jekyll-on-windows/) to get Jekyll up and running without problems.
2. From the root `/ImageProcessor` directory, run `jekyll serve` in the command line.
3. Open <http://localhost:4000> in your browser to navigate to your site.
Learn more about using Jekyll by reading its [documentation](http://jekyllrb.com/docs/home/).

61
old/appveyor.yml

@ -1,61 +0,0 @@
# http://www.appveyor.com/docs/appveyor-yml
#---------------------------------#
# general configuration #
#---------------------------------#
# branches to build
branches:
# blacklist
except:
- gh-pages
#---------------------------------#
# environment configuration #
#---------------------------------#
# Operating system (build VM template)
os: Windows Server 2012
# this is how to allow failing jobs in the matrix
matrix:
fast_finish: true # set this flag to immediately finish build once one of the jobs fails.
environment:
COVERALLS_REPO_TOKEN:
secure: 1hvfHFO3qtGTcwB+AnCGYsn0az0j9MzAux5hee5CFeyRJ+lWut0LjnyqvsI/5Pfa
#---------------------------------#
# build configuration #
#---------------------------------#
# to run your custom scripts instead of automatic MSBuild
before_build:
- ps: Import-Module .\build\psake.psm1
build_script:
- ps: Invoke-Psake .\build\build.ps1 -properties @{"BuildNumber"=$env:APPVEYOR_BUILD_NUMBER;"AppVeyor"=$env:APPVEYOR;"CoverallsRepoToken"=$env:COVERALLS_REPO_TOKEN}
#---------------------------------#
# tests configuration #
#---------------------------------#
# to disable automatic tests (they're included in the build process)
test: off
#---------------------------------#
# artifacts configuration #
#---------------------------------#
artifacts:
- path: build\_BuildOutput\NuGets\*.nupkg
#---------------------------------#
# global handlers #
#---------------------------------#
# on successful build
on_success:
- ps: Import-Module .\build\psake.psm1
- ps: Invoke-Psake .\build\build.ps1 Publish-Nuget -properties @{"NugetApiKey"=$env:APIKEY;"NugetSource"=$env:SOURCE}

5
old/build/Build.bat

@ -1,5 +0,0 @@
@echo off
powershell "Import-Module %~dp0\psake.psm1 ; Invoke-Psake %~dp0\build.ps1 ; exit $LASTEXITCODE"
pause

1
old/build/Doxyfile.REMOVED.git-id

@ -1 +0,0 @@
877afa6ca55ed11d2377363369ea1c39adace2d2

85
old/build/ImageProcessorDoc.shfbproj

@ -1,85 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
<PropertyGroup>
<!-- The configuration and platform will be used to determine which assemblies to include from solution and
project documentation sources -->
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{e3928e44-1c57-4c7e-9595-2a5b491455da}</ProjectGuid>
<SHFBSchemaVersion>1.9.9.0</SHFBSchemaVersion>
<!-- AssemblyName, Name, and RootNamespace are not used by SHFB but Visual Studio adds them anyway -->
<AssemblyName>Documentation</AssemblyName>
<RootNamespace>Documentation</RootNamespace>
<Name>Documentation</Name>
<!-- SHFB properties -->
<FrameworkVersion>.NET Framework 4.0</FrameworkVersion>
<OutputPath>_BuildOutput\Help\SandCastle\</OutputPath>
<HtmlHelpName>Documentation</HtmlHelpName>
<Language>en-US</Language>
<BuildAssemblerVerbosity>OnlyWarningsAndErrors</BuildAssemblerVerbosity>
<HelpFileFormat>HtmlHelp1</HelpFileFormat>
<IndentHtml>False</IndentHtml>
<KeepLogFile>True</KeepLogFile>
<DisableCodeBlockComponent>False</DisableCodeBlockComponent>
<CppCommentsFixup>False</CppCommentsFixup>
<CleanIntermediates>True</CleanIntermediates>
<MaximumGroupParts>2</MaximumGroupParts>
<NamespaceGrouping>False</NamespaceGrouping>
<SyntaxFilters>Standard</SyntaxFilters>
<SdkLinkTarget>Blank</SdkLinkTarget>
<RootNamespaceContainer>False</RootNamespaceContainer>
<PresentationStyle>VS2013</PresentationStyle>
<Preliminary>False</Preliminary>
<NamingMethod>Guid</NamingMethod>
<HelpTitle>ImageProcessor Documented Class Library</HelpTitle>
<ContentPlacement>AboveNamespaces</ContentPlacement>
<DocumentationSources>
<DocumentationSource sourceFile="_BuildOutput\ImageProcessor\lib\net45\ImageProcessor.dll" xmlns="" />
<DocumentationSource sourceFile="_BuildOutput\ImageProcessor\lib\net45\ImageProcessor.XML" xmlns="" />
</DocumentationSources>
<ProjectSummary>Imageprocessor is a lightweight library written in C# that allows you to manipulate images on-the-fly using .NET.
It&amp;#39%3bs fast, extensible, easy to use, comes bundled with some great features and is fully open source.
For full documentation please see http://imageprocessor.org/</ProjectSummary>
<NamespaceSummaries>
<NamespaceSummaryItem name="ImageProcessor" isDocumented="True" xmlns="">The main namespace for all features</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Common.Exceptions" isDocumented="True" xmlns="">Regroups the possible exceptions</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Common.Extensions" isDocumented="True" xmlns="">Regroups the extensions</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Configuration" isDocumented="True" xmlns="">The library configuration</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Imaging" isDocumented="True" xmlns="">The imaging components</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Imaging.Filters" isDocumented="True" xmlns="">The filters to apply on the images</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Imaging.Formats" isDocumented="True" xmlns="">The possible image formats</NamespaceSummaryItem>
<NamespaceSummaryItem name="ImageProcessor.Processors" isDocumented="True" xmlns="">The image processors</NamespaceSummaryItem>
</NamespaceSummaries>
<MissingTags>Summary, Parameter, Returns, AutoDocumentCtors, TypeParameter, AutoDocumentDispose</MissingTags>
<WorkingPath>_BuildOutput\Help\SandCastle\Working\</WorkingPath>
</PropertyGroup>
<!-- There are no properties for these groups. AnyCPU needs to appear in order for Visual Studio to perform
the build. The others are optional common platform types that may appear. -->
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|Win32' ">
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|Win32' ">
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\src\ImageProcessor\ImageProcessor.csproj">
<Name>ImageProcessor</Name>
<Project>{3B5DD734-FB7A-487D-8CE6-55E7AF9AEA7E}</Project>
</ProjectReference>
</ItemGroup>
<!-- Import the SHFB build targets -->
<Import Project="$(SHFBROOT)\SandcastleHelpFileBuilder.targets" />
</Project>

31
old/build/NuSpecs/ImageProcessor.Plugins.Cair.nuspec

@ -1,31 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>ImageProcessor.Plugins.Cair</id>
<version>1.0.1.0</version>
<title>ImageProcessor.Plugins.Cair</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Adds support to ImageProcessor for Content Aware Image Resizing.
If you use ImageProcessor please get in touch via my twitter @james_m_south
Feedback is always welcome</description>
<summary>Adds support to ImageProcessor for Content Aware Image Resizing.</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff Cair Seam Carving</tags>
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="ImageProcessor" version="2.2.3.0" />
</group>
</dependencies>
</metadata>
<files>
<file src="..\_BuildOutput\ImageProcessor.Plugins.Cair\lib\net45\ImageProcessor.Plugins.Cair.dll" target="lib\net45\ImageProcessor.Plugins.Cair.dll" />
</files>
</package>

32
old/build/NuSpecs/ImageProcessor.Plugins.WebP.nuspec

@ -1,32 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>ImageProcessor.Plugins.WebP</id>
<version>1.0.2.0</version>
<title>ImageProcessor.Plugins.WebP</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Adds support to ImageProcessor for the WebP image format.
If you use ImageProcessor please get in touch via my twitter @james_m_south
Feedback is always welcome</description>
<summary>Adds support to ImageProcessor and ImageProcessor.Web for the WebP image format.</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff WebP</tags>
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="ImageProcessor" version="2.2.3.0" />
</group>
</dependencies>
</metadata>
<files>
<file src="..\content\ImageProcessor.Plugins.WebP\web.config.transform" target="content\web.config.transform" />
<file src="..\_BuildOutput\ImageProcessor.Plugins.WebP\lib\net45\ImageProcessor.Plugins.WebP.dll" target="lib\net45\ImageProcessor.Plugins.WebP.dll" />
</files>
</package>

35
old/build/NuSpecs/ImageProcessor.Web.Config.nuspec

@ -1,35 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>ImageProcessor.Web.Config</id>
<version>2.2.1.0</version>
<title>ImageProcessor.Web.Config</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Adds configuration to your ImageProcessor.Web solution to allow you to override the default settings.
If you use ImageProcessor.Web please get in touch via my twitter @james_m_south
Feedback is always welcome</description>
<summary>ImageProcessor.Web configuration settings for ASP.NET websites.</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff ASP Cache EXIF</tags>
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="ImageProcessor" version="2.2.3.0" />
<dependency id="ImageProcessor.Web" version="4.3.0.0" />
</group>
</dependencies>
</metadata>
<files>
<file src="..\..\src\ImageProcessor.Web\Configuration\Resources\cache.config.transform" target="content\config\imageprocessor\cache.config.transform" />
<file src="..\..\src\ImageProcessor.Web\Configuration\Resources\processing.config.transform" target="content\config\imageprocessor\processing.config.transform" />
<file src="..\..\src\ImageProcessor.Web\Configuration\Resources\security.config.transform" target="content\config\imageprocessor\security.config.transform" />
<file src="..\content\ImageProcessor.Web.Config\web.config.transform" target="content\web.config.transform" />
</files>
</package>

41
old/build/NuSpecs/ImageProcessor.Web.Plugins.AzureBlobCache.nuspec

@ -1,41 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>ImageProcessor.Web.Plugins.AzureBlobCache</id>
<version>1.0.1.0</version>
<title>ImageProcessor.Web.Plugins.AzureBlobCache</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Adds a self cleaning cache that uses Azure Blob Containers to store processed images.
If you use ImageProcessor.Web please get in touch via my twitter @james_m_south
Feedback is always welcome</description>
<summary>ImageProcessor.Web AzureBlobCache for ASP.NET websites.</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff Azure Cache Asp</tags>
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="ImageProcessor" version="2.2.3.0" />
<dependency id="ImageProcessor.Web" version="4.3.0.0" />
<dependency id="ImageProcessor.Web.Config" version="2.2.1.0" />
<dependency id="Microsoft.Data.Edm" version="5.6.2" />
<dependency id="Microsoft.Data.OData" version="5.6.2" />
<dependency id="Microsoft.Data.Services.Client" version="5.6.2" />
<dependency id="Microsoft.WindowsAzure.ConfigurationManager" version="1.8.0.0" />
<dependency id="Newtonsoft.Json" version="5.0.8" />
<dependency id="System.Spatial" version="5.6.2" />
<dependency id="WindowsAzure.Storage" version="4.3.0" />
</group>
</dependencies>
</metadata>
<files>
<file src="..\content\ImageProcessor.Web.Plugins.AzureBlobCache\config\imageprocessor\cache.config.transform" target="content\config\imageprocessor\cache.config.transform" />
<file src="..\_BuildOutput\ImageProcessor.Web.Plugins.AzureBlobCache\lib\net45\ImageProcessor.Web.Plugins.AzureBlobCache.dll" target="lib\net45\ImageProcessor.Web.Plugins.AzureBlobCache.dll" />
</files>
</package>

32
old/build/NuSpecs/ImageProcessor.Web.PostProcessor.nuspec

@ -1,32 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>ImageProcessor.Web.PostProcessor</id>
<version>1.0.3.0</version>
<title>ImageProcessor.Web.PostProcessor</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Applies various image compression tools to further optimize cached .png, .gif, and .jpg images.
If you use ImageProcessor please get in touch via my twitter @james_m_south
Feedback is always welcome</description>
<summary>ImageProcessor.Web PostProcessor for ASP.NET websites.</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff ASP Cache EXIF</tags>
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="ImageProcessor" version="2.2.3.0" />
<dependency id="ImageProcessor.Web" version="4.3.0.0" />
</group>
</dependencies>
</metadata>
<files>
<file src="..\_BuildOutput\ImageProcessor.Web.PostProcessor\lib\net45\ImageProcessor.Web.PostProcessor.dll" target="lib\net45\ImageProcessor.Web.PostProcessor.dll" />
</files>
</package>

34
old/build/NuSpecs/ImageProcessor.Web.nuspec

@ -1,34 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>ImageProcessor.Web</id>
<version>4.3.0.0</version>
<title>ImageProcessor.Web</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>ImageProcessor.Web adds a configurable HttpModule to your website which allows on-the-fly processing of image files. The module also comes with a file and browser based cache that can handle millions of images, increasing your processing output and saving precious server memory.
Methods include: Resize, Rotate, Rounded Corners, Flip, Crop, Watermark, Filter, Saturation, Brightness, Contrast, Quality, Format, Vignette, Gaussian Blur, Gaussian Sharpen, and Transparency.
If you use ImageProcessor.Web please get in touch via my twitter @james_m_south
Feedback is always welcome</description>
<summary>An extension to ImageProcessor that allows on-the-fly processing of image files in an ASP.NET website</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff ASP Cache EXIF</tags>
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="ImageProcessor" version="2.2.3.0" />
</group>
</dependencies>
</metadata>
<files>
<file src="..\content\ImageProcessor.Web\web.config.transform" target="content\web.config.transform" />
<file src="..\_BuildOutput\ImageProcessor.Web\lib\net45\ImageProcessor.Web.dll" target="lib\net45\ImageProcessor.Web.dll" />
</files>
</package>

29
old/build/NuSpecs/ImageProcessor.nuspec

@ -1,29 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
<metadata>
<id>ImageProcessor</id>
<version>2.2.4.0</version>
<title>ImageProcessor</title>
<authors>James South</authors>
<owners>James South</owners>
<projectUrl>http://imageprocessor.org</projectUrl>
<iconUrl>http://imageprocessor.org/assets/ico/apple-touch-icon-144x144.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Image Processor is an easy to use and extend processing library written in C#. Its fluent API makes common imaging tasks very simple to perform.
Methods include; Resize, Rotate, Rounded Corners, Flip, Crop, Watermark, Filter, Saturation, Brightness, Contrast, Quality, Format, Vignette, Gaussian Blur, Gaussian Sharpen, and Transparency.
If you use ImageProcessor please get in touch on my twitter @james_m_south.
Feedback is always welcome.</description>
<summary>A library for manipulating image files written in C#.</summary>
<releaseNotes />
<copyright>James South</copyright>
<language>en-GB</language>
<tags>Image Resize Crop Rotate Quality Watermark Gif Jpg Jpeg Bitmap Png Tiff Fluent Animated EXIF</tags>
</metadata>
<files>
<file src="..\_BuildOutput\ImageProcessor\lib\net40\ImageProcessor.dll" target="lib\net40\ImageProcessor.dll" />
<file src="..\_BuildOutput\ImageProcessor\lib\net45\ImageProcessor.dll" target="lib\net45\ImageProcessor.dll" />
</files>
</package>

244
old/build/build.ps1

@ -1,244 +0,0 @@
Properties {
# call nuget.bat with these values as parameters
$NugetApiKey = $null
$NugetSource = $null
# see appveyor.yml for usage
$BuildNumber = $null
$CoverallsRepoToken = $null
$AppVeyor = $null
# Input and output paths
$BUILD_PATH = Resolve-Path "."
$SRC_PATH = Join-Path $BUILD_PATH "..\src"
$PLUGINS_PATH = Join-Path $SRC_PATH "Plugins\ImageProcessor"
$NUSPECS_PATH = Join-Path $BUILD_PATH "NuSpecs"
$BIN_PATH = Join-Path $BUILD_PATH "_BuildOutput"
$NUGET_OUTPUT = Join-Path $BIN_PATH "NuGets"
$TEST_RESULTS = Join-Path $BUILD_PATH "TestResults"
# API documentation
$API_BIN_PATH = Join-Path $BIN_PATH "ImageProcessor\lib\net45\ImageProcessor.dll" # from which DLL Docu builds its help output
$API_DOC_PATH = Join-Path $BIN_PATH "Help\docu"
# External binaries paths
$NUGET_EXE = Join-Path $SRC_PATH ".nuget\NuGet.exe"
$NUNIT_EXE = Join-Path $SRC_PATH "packages\NUnit.Runners.2.6.3\tools\nunit-console.exe"
$COVERALLS_EXE = Join-Path $SRC_PATH "packages\coveralls.io.1.3.2\tools\coveralls.net.exe"
$OPENCOVER_EXE = Join-Path $SRC_PATH "packages\OpenCover.4.5.3809-rc94\OpenCover.Console.exe"
$REPORTGEN_EXE = Join-Path $SRC_PATH "packages\ReportGenerator.1.9.1.0\ReportGenerator.exe"
$NUNITREPORT_EXE = Join-Path $BUILD_PATH "tools\NUnitHTMLReportGenerator.exe"
# list of projects
$PROJECTS_PATH = (Join-Path $BUILD_PATH "build.xml")
[xml]$PROJECTS = Get-Content $PROJECTS_PATH
$TestProjects = @(
"ImageProcessor.UnitTests",
"ImageProcessor.Web.UnitTests"
)
}
Framework "4.0x86"
FormatTaskName "-------- {0} --------"
task default -depends Cleanup-Binaries, Set-VersionNumber, Build-Solution, Run-Tests, Run-Coverage, Generate-Nuget
# cleans up the binaries output folder
task Cleanup-Binaries {
Write-Host "Removing binaries and artifacts so everything is nice and clean"
if (Test-Path $BIN_PATH) {
Remove-Item $BIN_PATH -Force -Recurse
}
if (Test-Path $NUGET_OUTPUT) {
Remove-Item $NUGET_OUTPUT -Force -Recurse
}
if (Test-Path $TEST_RESULTS) {
Remove-Item $TEST_RESULTS -Force -Recurse
}
}
# sets the version number from the build number in the build.xml file
task Set-VersionNumber {
if ($BuildNumber -eq $null -or $BuildNumber -eq "") {
return
}
$PROJECTS.projects.project | % {
if ($_.version -match "([\d+\.]*)[\d+|\*]") { # get numbers of current version except last one
$_.version = "$($Matches[1])$BuildNumber"
}
}
$PROJECTS.Save($PROJECTS_PATH)
}
# builds the solutions
task Build-Solution -depends Cleanup-Binaries, Set-VersionNumber {
Write-Host "Building projects"
# build the projects
# regular "$xmlobject.node | % { $_ }" don't work when they're nested: http://fredmorrison.wordpress.com/2013/03/19/reading-xml-with-powershell-why-most-examples-you-see-are-wrong/
[System.Xml.XmlElement] $root = $PROJECTS.get_DocumentElement()
[System.Xml.XmlElement] $project = $null
foreach($project in $root.ChildNodes) {
if ($project.projfile -eq $null -or $project.projfile -eq "") {
continue # goes to next item
}
$projectPath = Resolve-Path $project.folder
Write-Host "Building project $($project.name) at version $($project.version)"
# it would be possible to update more infos from the xml (description etc), so as to have all infos in one place
Update-AssemblyInfo -file (Join-Path $projectPath "Properties\AssemblyInfo.cs") -version $project.version
[System.Xml.XmlElement] $output = $null
foreach($output in $project.outputs.ChildNodes) {
# using invoke-expression solves a few character escape issues
$buildCommand = "msbuild $(Join-Path $projectPath $project.projfile) /t:Build /p:Warnings=true /p:Configuration=Release /p:PipelineDependsOnBuild=False /p:OutDir=$(Join-Path $BIN_PATH $output.folder) $($output.additionalParameters) /clp:WarningsOnly /clp:ErrorsOnly /clp:Summary /clp:PerformanceSummary /v:Normal /nologo"
Write-Host $buildCommand -ForegroundColor DarkGreen
Exec {
Invoke-Expression $buildCommand
}
}
}
}
# builds the test projects
task Build-Tests -depends Cleanup-Binaries {
Write-Host "Building the unit test projects"
if (-not (Test-Path $TEST_RESULTS)) {
mkdir $TEST_RESULTS | Out-Null
}
# make sure the runner exes are restored
& $NUGET_EXE restore (Join-Path $SRC_PATH "ImageProcessor.sln")
# build the test projects
$TestProjects | % {
Write-Host "Building project $_"
Exec {
msbuild (Join-Path $SRC_PATH "$_\$_.csproj") /t:Build /p:Configuration=Release /p:Platform="AnyCPU" /p:Warnings=true /clp:WarningsOnly /clp:ErrorsOnly /v:Normal /nologo
}
}
}
# runs the unit tests
task Run-Tests -depends Build-Tests {
Write-Host "Running unit tests"
$TestProjects | % {
$TestDllFolder = Join-Path $SRC_PATH "$_\bin\Release"
$TestDdlPath = Join-Path $TestDllFolder "$_.dll"
$TestOutputPath = Join-Path $TEST_RESULTS "$($_)_Unit.xml"
Write-Host "Running unit tests on project $_"
& $NUNIT_EXE $TestDdlPath /result:$TestOutputPath /noshadow /nologo
$ReportPath = (Join-Path $TEST_RESULTS "Tests")
if (-not (Test-Path $ReportPath)) {
mkdir $ReportPath | Out-Null
}
Write-Host "Transforming tests results file to HTML"
& $NUNITREPORT_EXE $TestOutputPath (Join-Path $ReportPath "$_.html")
}
}
# runs the code coverage (separate from the unit test because it takes so much longer)
task Run-Coverage -depends Build-Tests {
Write-Host "Running code coverage over unit tests"
$TestProjects | % {
$TestDllFolder = Join-Path $SRC_PATH "$_\bin\Release"
$TestDdlPath = Join-Path $TestDllFolder "$_.dll"
$CoverageOutputPath = Join-Path $TEST_RESULTS "$($_)_Coverage.xml"
Write-Host "AppVeyor $AppVeyor"
$appVeyor = ""
if ($AppVeyor -ne $null -and $AppVeyor -ne "") {
$appVeyor = " -appveyor"
}
Write-Host "Running code coverage on project $_"
$coverageFilter = "-filter:+[*]* -[FluentAssertions*]* -[ImageProcessor]*Common.Exceptions -[ImageProcessor.UnitTests]* -[ImageProcessor.Web.UnitTests]*"
& $OPENCOVER_EXE -threshold:1 -oldstyle -register:user -target:$NUNIT_EXE -targetargs:"$TestDdlPath /noshadow /nologo" $appVeyor -targetdir:$TestDllFolder -output:$CoverageOutputPath $coverageFilter
Write-Host "Transforming coverage results file to HTML"
& $REPORTGEN_EXE -verbosity:Info -reports:$CoverageOutputPath -targetdir:(Join-Path $TEST_RESULTS "Coverage\$_")
Write-Host "CoverallsRepoToken $CoverallsRepoToken"
if ($CoverallsRepoToken -ne $null -and $CoverallsRepoToken -ne "") {
Write-Host "Uploading coverage report to Coveralls.io"
Exec { . $COVERALLS_EXE --opencover $CoverageOutputPath }
}
}
}
# generates the API documentation. Disabled for now.
task Generate-APIDoc -depends Build-Solution {
Write-Host "Generating API docs"
& .\tools\docu\docu.exe $API_BIN_PATH --output=$API_DOC_PATH
& .\tools\doxygen\doxygen.exe .\Doxyfile
}
# generates a Nuget package
task Generate-Nuget -depends Set-VersionNumber, Build-Solution {
Write-Host "Generating Nuget packages for each project"
# Nuget doesn't create the output dir automatically...
if (-not (Test-Path $NUGET_OUTPUT)) {
mkdir $NUGET_OUTPUT | Out-Null
}
# Package the nuget
$PROJECTS.projects.project | % {
$nuspec_local_path = (Join-Path $NUSPECS_PATH $_.nuspec)
Write-Host "Building Nuget package from $nuspec_local_path"
# change the version values
[xml]$nuspec_contents = Get-Content $nuspec_local_path
$nuspec_contents.package.metadata.version = $_.version
$nuspec_contents.Save($nuspec_local_path)
if ((-not (Test-Path $nuspec_local_path)) -or (-not (Test-Path $NUGET_OUTPUT))) {
throw New-Object [System.IO.FileNotFoundException] "The file $nuspec_local_path or $NUGET_OUTPUT could not be found"
}
# pack the nuget
& $NUGET_EXE Pack $nuspec_local_path -OutputDirectory $NUGET_OUTPUT
}
}
# publishes the nuget on a feed
task Publish-Nuget {
if ($NugetApiKey -eq $null -or $NugetApiKey -eq "") {
throw New-Object [System.ArgumentException] "You must provide an API key as parameter: 'Invoke-psake Publish-Nuget -properties @{`"NugetApiKey`"=`"YOURAPIKEY`"}' ; or add a APIKEY environment variable to AppVeyor"
}
Get-ChildItem $NUGET_OUTPUT -Filter "*.nugpkg" | % {
if ($NugetSource -eq $null -or $NugetSource -eq "") {
& $NUGET_EXE push $_ -ApiKey $apikey -Source $NugetSource
} else {
& $NUGET_EXE push $_ -ApiKey $apikey
}
}
}
# updates the AssemblyInfo file with the specified version
# http://www.luisrocha.net/2009/11/setting-assembly-version-with-windows.html
function Update-AssemblyInfo ([string]$file, [string] $version) {
$assemblyVersionPattern = 'AssemblyVersion\("[0-9]+(\.([0-9]+|\*)){1,3}"\)'
$fileVersionPattern = 'AssemblyFileVersion\("[0-9]+(\.([0-9]+|\*)){1,3}"\)'
$assemblyVersion = 'AssemblyVersion("' + $version + '")';
$fileVersion = 'AssemblyFileVersion("' + $version + '")';
(Get-Content $file) | ForEach-Object {
% {$_ -replace $assemblyVersionPattern, $assemblyVersion } |
% {$_ -replace $fileVersionPattern, $fileVersion }
} | Set-Content $file
}

74
old/build/build.xml

@ -1,74 +0,0 @@
<projects>
<project>
<name>ImageProcessor</name>
<version>2.2.4.0</version>
<folder>..\src\ImageProcessor</folder>
<projfile>ImageProcessor.csproj</projfile>
<outputs>
<output additionalParameters="/p:Framework=NET40" folder="ImageProcessor\lib\net40" />
<output additionalParameters="/p:Framework=NET45" folder="ImageProcessor\lib\net45" />
</outputs>
<nuspec>ImageProcessor.nuspec</nuspec>
</project>
<project>
<name>ImageProcessor Web</name>
<version>4.3.0.0</version>
<folder>..\src\ImageProcessor.Web</folder>
<projfile>ImageProcessor.Web.csproj</projfile>
<outputs>
<output folder="ImageProcessor.Web\lib\net45" />
</outputs>
<nuspec>ImageProcessor.Web.nuspec</nuspec>
</project>
<project>
<name>ImageProcessor Web.config sample</name>
<version>2.2.1.0</version>
<nuspec>ImageProcessor.Web.Config.nuspec</nuspec>
</project>
<project>
<name>ImageProcessor Web PostProcessor</name>
<version>1.0.3.0</version>
<folder>..\src\ImageProcessor.Web.PostProcessor</folder>
<projfile>ImageProcessor.Web.PostProcessor.csproj</projfile>
<outputs>
<output folder="ImageProcessor.Web.PostProcessor\lib\net45" />
</outputs>
<nuspec>ImageProcessor.Web.PostProcessor.nuspec</nuspec>
</project>
<project>
<name>ImageProcessor Web Azure Blob Cache plugin</name>
<version>1.0.1.0</version>
<folder>..\src\Plugins\ImageProcessor.Web\ImageProcessor.Web.Plugins.AzureBlobCache</folder>
<projfile>ImageProcessor.Web.Plugins.AzureBlobCache.csproj</projfile>
<outputs>
<output folder="ImageProcessor.Web.Plugins.AzureBlobCache\lib\net45" />
</outputs>
<nuspec>ImageProcessor.Web.Plugins.AzureBlobCache.nuspec</nuspec>
</project>
<project>
<name>ImageProcessor Cair plugin</name>
<version>1.0.1.0</version>
<folder>..\src\Plugins\ImageProcessor\ImageProcessor.Plugins.Cair</folder>
<projfile>ImageProcessor.Plugins.Cair.csproj</projfile>
<outputs>
<output folder="ImageProcessor.Plugins.Cair\lib\net45" />
</outputs>
<nuspec>ImageProcessor.Plugins.Cair.nuspec</nuspec>
</project>
<project>
<name>ImageProcessor WebP plugin</name>
<version>1.0.2.0</version>
<folder>..\src\Plugins\ImageProcessor\ImageProcessor.Plugins.WebP</folder>
<projfile>ImageProcessor.Plugins.WebP.csproj</projfile>
<outputs>
<output folder="ImageProcessor.Plugins.WebP\lib\net45" />
</outputs>
<nuspec>ImageProcessor.Plugins.WebP.nuspec</nuspec>
</project>
</projects>

9
old/build/content/ImageProcessor.Plugins.WebP/web.config.transform

@ -1,9 +0,0 @@
<?xml version="1.0"?>
<configuration>
<system.webServer>
<staticContent>
<remove fileExtension=".webp"/>
<mimeMap fileExtension=".webp" mimeType="image/webp" />
</staticContent>
</system.webServer>
</configuration>

16
old/build/content/ImageProcessor.Web.Config/web.config.transform

@ -1,16 +0,0 @@
<?xml version="1.0"?>
<configuration>
<configSections>
<sectionGroup name="imageProcessor">
<section name="security" requirePermission="false" type="ImageProcessor.Web.Configuration.ImageSecuritySection, ImageProcessor.Web"/>
<section name="processing" requirePermission="false" type="ImageProcessor.Web.Configuration.ImageProcessingSection, ImageProcessor.Web"/>
<section name="caching" requirePermission="false" type="ImageProcessor.Web.Configuration.ImageCacheSection, ImageProcessor.Web"/>
</sectionGroup>
</configSections>
<imageProcessor>
<security configSource="config\imageprocessor\security.config" />
<caching configSource="config\imageprocessor\cache.config" />
<processing configSource="config\imageprocessor\processing.config" />
</imageProcessor>
</configuration>

14
old/build/content/ImageProcessor.Web.Plugins.AzureBlobCache/config/imageprocessor/cache.config.transform

@ -1,14 +0,0 @@
<caching currentCache="AzureBlobCache">
<caches>
<cache name="AzureBlobCache" type="ImageProcessor.Web.Plugins.AzureBlobCache.AzureBlobCache, ImageProcessor.Web.Plugins.AzureBlobCache" maxDays="365">
<settings>
<setting key="CachedStorageAccount" value="DefaultEndpointsProtocol=https;AccountName=[CacheAccountName];AccountKey=[CacheAccountKey]"/>
<setting key="CachedBlobContainer" value="cache"/>
<setting key="CachedCDNRoot" value="[CdnRootUrl]"/>
<setting key="SourceStorageAccount" value=""/>
<setting key="SourceBlobContainer" value=""/>
</settings>
</cache>
</caches>
</caching>

14
old/build/content/ImageProcessor.Web/web.config.transform

@ -1,14 +0,0 @@
<?xml version="1.0"?>
<configuration>
<system.web>
<httpModules>
<add name="ImageProcessorModule" type="ImageProcessor.Web.HttpModules.ImageProcessingModule, ImageProcessor.Web"/>
</httpModules>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false" />
<modules>
<add name="ImageProcessorModule" type="ImageProcessor.Web.HttpModules.ImageProcessingModule, ImageProcessor.Web"/>
</modules>
</system.webServer>
</configuration>

5
old/build/coverage.bat

@ -1,5 +0,0 @@
@echo off
powershell "Import-Module %~dp0\psake.psm1 ; Invoke-Psake %~dp0\build.ps1 Run-Coverage ; exit $LASTEXITCODE"
pause

847
old/build/psake.psm1

@ -1,847 +0,0 @@
# psake
# Copyright (c) 2012 James Kovacs
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.
#Requires -Version 2.0
#-- Public Module Functions --#
# .ExternalHelp psake.psm1-help.xml
function Invoke-Task
{
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)] [string]$taskName
)
Assert $taskName ($msgs.error_invalid_task_name)
$taskKey = $taskName.ToLower()
if ($currentContext.aliases.Contains($taskKey)) {
$taskName = $currentContext.aliases.$taskKey.Name
$taskKey = $taskName.ToLower()
}
$currentContext = $psake.context.Peek()
Assert ($currentContext.tasks.Contains($taskKey)) ($msgs.error_task_name_does_not_exist -f $taskName)
if ($currentContext.executedTasks.Contains($taskKey)) { return }
Assert (!$currentContext.callStack.Contains($taskKey)) ($msgs.error_circular_reference -f $taskName)
$currentContext.callStack.Push($taskKey)
$task = $currentContext.tasks.$taskKey
$precondition_is_valid = & $task.Precondition
if (!$precondition_is_valid) {
WriteColoredOutput ($msgs.precondition_was_false -f $taskName) -foregroundcolor Cyan
} else {
if ($taskKey -ne 'default') {
if ($task.PreAction -or $task.PostAction) {
Assert ($task.Action -ne $null) ($msgs.error_missing_action_parameter -f $taskName)
}
if ($task.Action) {
try {
foreach($childTask in $task.DependsOn) {
Invoke-Task $childTask
}
$stopwatch = [System.Diagnostics.Stopwatch]::StartNew()
$currentContext.currentTaskName = $taskName
& $currentContext.taskSetupScriptBlock
if ($task.PreAction) {
& $task.PreAction
}
if ($currentContext.config.taskNameFormat -is [ScriptBlock]) {
& $currentContext.config.taskNameFormat $taskName
} else {
WriteColoredOutput ($currentContext.config.taskNameFormat -f $taskName) -foregroundcolor Cyan
}
foreach ($variable in $task.requiredVariables) {
Assert ((test-path "variable:$variable") -and ((get-variable $variable).Value -ne $null)) ($msgs.required_variable_not_set -f $variable, $taskName)
}
& $task.Action
if ($task.PostAction) {
& $task.PostAction
}
& $currentContext.taskTearDownScriptBlock
$task.Duration = $stopwatch.Elapsed
} catch {
if ($task.ContinueOnError) {
"-"*70
WriteColoredOutput ($msgs.continue_on_error -f $taskName,$_) -foregroundcolor Yellow
"-"*70
$task.Duration = $stopwatch.Elapsed
} else {
throw $_
}
}
} else {
# no action was specified but we still execute all the dependencies
foreach($childTask in $task.DependsOn) {
Invoke-Task $childTask
}
}
} else {
foreach($childTask in $task.DependsOn) {
Invoke-Task $childTask
}
}
Assert (& $task.Postcondition) ($msgs.postcondition_failed -f $taskName)
}
$poppedTaskKey = $currentContext.callStack.Pop()
Assert ($poppedTaskKey -eq $taskKey) ($msgs.error_corrupt_callstack -f $taskKey,$poppedTaskKey)
$currentContext.executedTasks.Push($taskKey)
}
# .ExternalHelp psake.psm1-help.xml
function Exec
{
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][scriptblock]$cmd,
[Parameter(Position=1,Mandatory=0)][string]$errorMessage = ($msgs.error_bad_command -f $cmd),
[Parameter(Position=2,Mandatory=0)][int]$maxRetries = 0,
[Parameter(Position=3,Mandatory=0)][string]$retryTriggerErrorPattern = $null
)
$tryCount = 1
do {
try {
$global:lastexitcode = 0
& $cmd
if ($lastexitcode -ne 0) {
throw ("Exec: " + $errorMessage)
}
break
}
catch [Exception]
{
if ($tryCount -gt $maxRetries) {
throw $_
}
if ($retryTriggerErrorPattern -ne $null) {
$isMatch = [regex]::IsMatch($_.Exception.Message, $retryTriggerErrorPattern)
if ($isMatch -eq $false) {
throw $_
}
}
Write-Host "Try $tryCount failed, retrying again in 1 second..."
$tryCount++
[System.Threading.Thread]::Sleep([System.TimeSpan]::FromSeconds(1))
}
}
while ($true)
}
# .ExternalHelp psake.psm1-help.xml
function Assert
{
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)]$conditionToCheck,
[Parameter(Position=1,Mandatory=1)]$failureMessage
)
if (!$conditionToCheck) {
throw ("Assert: " + $failureMessage)
}
}
# .ExternalHelp psake.psm1-help.xml
function Task
{
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][string]$name = $null,
[Parameter(Position=1,Mandatory=0)][scriptblock]$action = $null,
[Parameter(Position=2,Mandatory=0)][scriptblock]$preaction = $null,
[Parameter(Position=3,Mandatory=0)][scriptblock]$postaction = $null,
[Parameter(Position=4,Mandatory=0)][scriptblock]$precondition = {$true},
[Parameter(Position=5,Mandatory=0)][scriptblock]$postcondition = {$true},
[Parameter(Position=6,Mandatory=0)][switch]$continueOnError = $false,
[Parameter(Position=7,Mandatory=0)][string[]]$depends = @(),
[Parameter(Position=8,Mandatory=0)][string[]]$requiredVariables = @(),
[Parameter(Position=9,Mandatory=0)][string]$description = $null,
[Parameter(Position=10,Mandatory=0)][string]$alias = $null,
[Parameter(Position=11,Mandatory=0)][string]$maxRetries = 0,
[Parameter(Position=12,Mandatory=0)][string]$retryTriggerErrorPattern = $null
)
if ($name -eq 'default') {
Assert (!$action) ($msgs.error_default_task_cannot_have_action)
}
$newTask = @{
Name = $name
DependsOn = $depends
PreAction = $preaction
Action = $action
PostAction = $postaction
Precondition = $precondition
Postcondition = $postcondition
ContinueOnError = $continueOnError
Description = $description
Duration = [System.TimeSpan]::Zero
RequiredVariables = $requiredVariables
Alias = $alias
MaxRetries = $maxRetries
RetryTriggerErrorPattern = $retryTriggerErrorPattern
}
$taskKey = $name.ToLower()
$currentContext = $psake.context.Peek()
Assert (!$currentContext.tasks.ContainsKey($taskKey)) ($msgs.error_duplicate_task_name -f $name)
$currentContext.tasks.$taskKey = $newTask
if($alias)
{
$aliasKey = $alias.ToLower()
Assert (!$currentContext.aliases.ContainsKey($aliasKey)) ($msgs.error_duplicate_alias_name -f $alias)
$currentContext.aliases.$aliasKey = $newTask
}
}
# .ExternalHelp psake.psm1-help.xml
function Properties {
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][scriptblock]$properties
)
$psake.context.Peek().properties += $properties
}
# .ExternalHelp psake.psm1-help.xml
function Include {
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][string]$fileNamePathToInclude
)
Assert (test-path $fileNamePathToInclude -pathType Leaf) ($msgs.error_invalid_include_path -f $fileNamePathToInclude)
$psake.context.Peek().includes.Enqueue((Resolve-Path $fileNamePathToInclude));
}
# .ExternalHelp psake.psm1-help.xml
function FormatTaskName {
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)]$format
)
$psake.context.Peek().config.taskNameFormat = $format
}
# .ExternalHelp psake.psm1-help.xml
function TaskSetup {
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][scriptblock]$setup
)
$psake.context.Peek().taskSetupScriptBlock = $setup
}
# .ExternalHelp psake.psm1-help.xml
function TaskTearDown {
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][scriptblock]$teardown
)
$psake.context.Peek().taskTearDownScriptBlock = $teardown
}
# .ExternalHelp psake.psm1-help.xml
function Framework {
[CmdletBinding()]
param(
[Parameter(Position=0,Mandatory=1)][string]$framework
)
$psake.context.Peek().config.framework = $framework
ConfigureBuildEnvironment
}
# .ExternalHelp psake.psm1-help.xml
function Invoke-psake {
[CmdletBinding()]
param(
[Parameter(Position = 0, Mandatory = 0)][string] $buildFile,
[Parameter(Position = 1, Mandatory = 0)][string[]] $taskList = @(),
[Parameter(Position = 2, Mandatory = 0)][string] $framework,
[Parameter(Position = 3, Mandatory = 0)][switch] $docs = $false,
[Parameter(Position = 4, Mandatory = 0)][hashtable] $parameters = @{},
[Parameter(Position = 5, Mandatory = 0)][hashtable] $properties = @{},
[Parameter(Position = 6, Mandatory = 0)][alias("init")][scriptblock] $initialization = {},
[Parameter(Position = 7, Mandatory = 0)][switch] $nologo = $false
)
try {
if (-not $nologo) {
"psake version {0}`nCopyright (c) 2010 James Kovacs`n" -f $psake.version
}
if (!$buildFile) {
$buildFile = $psake.config_default.buildFileName
}
elseif (!(test-path $buildFile -pathType Leaf) -and (test-path $psake.config_default.buildFileName -pathType Leaf)) {
# If the $config.buildFileName file exists and the given "buildfile" isn 't found assume that the given
# $buildFile is actually the target Tasks to execute in the $config.buildFileName script.
$taskList = $buildFile.Split(', ')
$buildFile = $psake.config_default.buildFileName
}
# Execute the build file to set up the tasks and defaults
Assert (test-path $buildFile -pathType Leaf) ($msgs.error_build_file_not_found -f $buildFile)
$psake.build_script_file = get-item $buildFile
$psake.build_script_dir = $psake.build_script_file.DirectoryName
$psake.build_success = $false
$psake.context.push(@{
"taskSetupScriptBlock" = {};
"taskTearDownScriptBlock" = {};
"executedTasks" = new-object System.Collections.Stack;
"callStack" = new-object System.Collections.Stack;
"originalEnvPath" = $env:path;
"originalDirectory" = get-location;
"originalErrorActionPreference" = $global:ErrorActionPreference;
"tasks" = @{};
"aliases" = @{};
"properties" = @();
"includes" = new-object System.Collections.Queue;
"config" = CreateConfigurationForNewContext $buildFile $framework
})
LoadConfiguration $psake.build_script_dir
$stopwatch = [System.Diagnostics.Stopwatch]::StartNew()
set-location $psake.build_script_dir
LoadModules
$frameworkOldValue = $framework
. $psake.build_script_file.FullName
$currentContext = $psake.context.Peek()
if ($framework -ne $frameworkOldValue) {
writecoloredoutput $msgs.warning_deprecated_framework_variable -foregroundcolor Yellow
$currentContext.config.framework = $framework
}
ConfigureBuildEnvironment
while ($currentContext.includes.Count -gt 0) {
$includeFilename = $currentContext.includes.Dequeue()
. $includeFilename
}
if ($docs) {
WriteDocumentation
CleanupEnvironment
return
}
foreach ($key in $parameters.keys) {
if (test-path "variable:\$key") {
set-item -path "variable:\$key" -value $parameters.$key -WhatIf:$false -Confirm:$false | out-null
} else {
new-item -path "variable:\$key" -value $parameters.$key -WhatIf:$false -Confirm:$false | out-null
}
}
# The initial dot (.) indicates that variables initialized/modified in the propertyBlock are available in the parent scope.
foreach ($propertyBlock in $currentContext.properties) {
. $propertyBlock
}
foreach ($key in $properties.keys) {
if (test-path "variable:\$key") {
set-item -path "variable:\$key" -value $properties.$key -WhatIf:$false -Confirm:$false | out-null
}
}
# Simple dot sourcing will not work. We have to force the script block into our
# module's scope in order to initialize variables properly.
. $MyInvocation.MyCommand.Module $initialization
# Execute the list of tasks or the default task
if ($taskList) {
foreach ($task in $taskList) {
invoke-task $task
}
} elseif ($currentContext.tasks.default) {
invoke-task default
} else {
throw $msgs.error_no_default_task
}
WriteColoredOutput ("`n" + $msgs.build_success + "`n") -foregroundcolor Green
WriteTaskTimeSummary $stopwatch.Elapsed
$psake.build_success = $true
} catch {
$currentConfig = GetCurrentConfigurationOrDefault
if ($currentConfig.verboseError) {
$error_message = "{0}: An Error Occurred. See Error Details Below: `n" -f (Get-Date)
$error_message += ("-" * 70) + "`n"
$error_message += "Error: {0}`n" -f (ResolveError $_ -Short)
$error_message += ("-" * 70) + "`n"
$error_message += ResolveError $_
$error_message += ("-" * 70) + "`n"
$error_message += "Script Variables" + "`n"
$error_message += ("-" * 70) + "`n"
$error_message += get-variable -scope script | format-table | out-string
} else {
# ($_ | Out-String) gets error messages with source information included.
$error_message = "Error: {0}: `n{1}" -f (Get-Date), (ResolveError $_ -Short)
}
$psake.build_success = $false
# if we are running in a nested scope (i.e. running a psake script from a psake script) then we need to re-throw the exception
# so that the parent script will fail otherwise the parent script will report a successful build
$inNestedScope = ($psake.context.count -gt 1)
if ( $inNestedScope ) {
throw $_
} else {
if (!$psake.run_by_psake_build_tester) {
WriteColoredOutput $error_message -foregroundcolor Red
}
}
} finally {
CleanupEnvironment
}
}
#-- Private Module Functions --#
function WriteColoredOutput {
param(
[string] $message,
[System.ConsoleColor] $foregroundcolor
)
$currentConfig = GetCurrentConfigurationOrDefault
if ($currentConfig.coloredOutput -eq $true) {
if (($Host.UI -ne $null) -and ($Host.UI.RawUI -ne $null) -and ($Host.UI.RawUI.ForegroundColor -ne $null)) {
$previousColor = $Host.UI.RawUI.ForegroundColor
$Host.UI.RawUI.ForegroundColor = $foregroundcolor
}
}
$message
if ($previousColor -ne $null) {
$Host.UI.RawUI.ForegroundColor = $previousColor
}
}
function LoadModules {
$currentConfig = $psake.context.peek().config
if ($currentConfig.modules) {
$scope = $currentConfig.moduleScope
$global = [string]::Equals($scope, "global", [StringComparison]::CurrentCultureIgnoreCase)
$currentConfig.modules | foreach {
resolve-path $_ | foreach {
"Loading module: $_"
$module = import-module $_ -passthru -DisableNameChecking -global:$global
if (!$module) {
throw ($msgs.error_loading_module -f $_.Name)
}
}
}
""
}
}
function LoadConfiguration {
param(
[string] $configdir = $PSScriptRoot
)
$psakeConfigFilePath = (join-path $configdir "psake-config.ps1")
if (test-path $psakeConfigFilePath -pathType Leaf) {
try {
$config = GetCurrentConfigurationOrDefault
. $psakeConfigFilePath
} catch {
throw "Error Loading Configuration from psake-config.ps1: " + $_
}
}
}
function GetCurrentConfigurationOrDefault() {
if ($psake.context.count -gt 0) {
return $psake.context.peek().config
} else {
return $psake.config_default
}
}
function CreateConfigurationForNewContext {
param(
[string] $buildFile,
[string] $framework
)
$previousConfig = GetCurrentConfigurationOrDefault
$config = new-object psobject -property @{
buildFileName = $previousConfig.buildFileName;
framework = $previousConfig.framework;
taskNameFormat = $previousConfig.taskNameFormat;
verboseError = $previousConfig.verboseError;
coloredOutput = $previousConfig.coloredOutput;
modules = $previousConfig.modules;
moduleScope = $previousConfig.moduleScope;
}
if ($framework) {
$config.framework = $framework;
}
if ($buildFile) {
$config.buildFileName = $buildFile;
}
return $config
}
function ConfigureBuildEnvironment {
$framework = $psake.context.peek().config.framework
if ($framework -cmatch '^((?:\d+\.\d+)(?:\.\d+){0,1})(x86|x64){0,1}$') {
$versionPart = $matches[1]
$bitnessPart = $matches[2]
} else {
throw ($msgs.error_invalid_framework -f $framework)
}
$versions = $null
$buildToolsVersions = $null
switch ($versionPart) {
'1.0' {
$versions = @('v1.0.3705')
}
'1.1' {
$versions = @('v1.1.4322')
}
'2.0' {
$versions = @('v2.0.50727')
}
'3.0' {
$versions = @('v2.0.50727')
}
'3.5' {
$versions = @('v3.5', 'v2.0.50727')
}
'4.0' {
$versions = @('v4.0.30319')
}
'4.5.1' {
$versions = @('v4.0.30319')
$buildToolsVersions = @('12.0')
}
default {
throw ($msgs.error_unknown_framework -f $versionPart, $framework)
}
}
$bitness = 'Framework'
if ($versionPart -ne '1.0' -and $versionPart -ne '1.1') {
switch ($bitnessPart) {
'x86' {
$bitness = 'Framework'
$buildToolsKey = 'MSBuildToolsPath32'
}
'x64' {
$bitness = 'Framework64'
$buildToolsKey = 'MSBuildToolsPath'
}
{ [string]::IsNullOrEmpty($_) } {
$ptrSize = [System.IntPtr]::Size
switch ($ptrSize) {
4 {
$bitness = 'Framework'
$buildToolsKey = 'MSBuildToolsPath32'
}
8 {
$bitness = 'Framework64'
$buildToolsKey = 'MSBuildToolsPath'
}
default {
throw ($msgs.error_unknown_pointersize -f $ptrSize)
}
}
}
default {
throw ($msgs.error_unknown_bitnesspart -f $bitnessPart, $framework)
}
}
}
$frameworkDirs = @()
if ($buildToolsVersions -ne $null) {
$frameworkDirs = @($buildToolsVersions | foreach { (Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\MSBuild\ToolsVersions\$_" -Name $buildToolsKey).$buildToolsKey })
}
$frameworkDirs = $frameworkDirs + @($versions | foreach { "$env:windir\Microsoft.NET\$bitness\$_\" })
for ($i = 0; $i -lt $frameworkDirs.Count; $i++) {
$dir = $frameworkDirs[$i]
if ($dir -Match "\$\(Registry:HKEY_LOCAL_MACHINE(.*?)@(.*)\)") {
$key = "HKLM:" + $matches[1]
$name = $matches[2]
$dir = (Get-ItemProperty -Path $key -Name $name).$name
$frameworkDirs[$i] = $dir
}
}
$frameworkDirs | foreach { Assert (test-path $_ -pathType Container) ($msgs.error_no_framework_install_dir_found -f $_)}
$env:path = ($frameworkDirs -join ";") + ";$env:path"
# if any error occurs in a PS function then "stop" processing immediately
# this does not effect any external programs that return a non-zero exit code
$global:ErrorActionPreference = "Stop"
}
function CleanupEnvironment {
if ($psake.context.Count -gt 0) {
$currentContext = $psake.context.Peek()
$env:path = $currentContext.originalEnvPath
Set-Location $currentContext.originalDirectory
$global:ErrorActionPreference = $currentContext.originalErrorActionPreference
[void] $psake.context.Pop()
}
}
function SelectObjectWithDefault
{
[CmdletBinding()]
param(
[Parameter(ValueFromPipeline=$true)]
[PSObject]
$InputObject,
[string]
$Name,
$Value
)
process {
if ($_ -eq $null) { $Value }
elseif ($_ | Get-Member -Name $Name) {
$_.$Name
}
elseif (($_ -is [Hashtable]) -and ($_.Keys -contains $Name)) {
$_.$Name
}
else { $Value }
}
}
# borrowed from Jeffrey Snover http://blogs.msdn.com/powershell/archive/2006/12/07/resolve-error.aspx
# modified to better handle SQL errors
function ResolveError
{
[CmdletBinding()]
param(
[Parameter(ValueFromPipeline=$true)]
$ErrorRecord=$Error[0],
[Switch]
$Short
)
process {
if ($_ -eq $null) { $_ = $ErrorRecord }
$ex = $_.Exception
if (-not $Short) {
$error_message = "`nErrorRecord:{0}ErrorRecord.InvocationInfo:{1}Exception:`n{2}"
$formatted_errorRecord = $_ | format-list * -force | out-string
$formatted_invocationInfo = $_.InvocationInfo | format-list * -force | out-string
$formatted_exception = ''
$i = 0
while ($ex -ne $null) {
$i++
$formatted_exception += ("$i" * 70) + "`n" +
($ex | format-list * -force | out-string) + "`n"
$ex = $ex | SelectObjectWithDefault -Name 'InnerException' -Value $null
}
return $error_message -f $formatted_errorRecord, $formatted_invocationInfo, $formatted_exception
}
$lastException = @()
while ($ex -ne $null) {
$lastMessage = $ex | SelectObjectWithDefault -Name 'Message' -Value ''
$lastException += ($lastMessage -replace "`n", '')
if ($ex -is [Data.SqlClient.SqlException]) {
$lastException += "(Line [$($ex.LineNumber)] " +
"Procedure [$($ex.Procedure)] Class [$($ex.Class)] " +
" Number [$($ex.Number)] State [$($ex.State)] )"
}
$ex = $ex | SelectObjectWithDefault -Name 'InnerException' -Value $null
}
$shortException = $lastException -join ' --> '
$header = $null
$current = $_
$header = (($_.InvocationInfo |
SelectObjectWithDefault -Name 'PositionMessage' -Value '') -replace "`n", ' '),
($_ | SelectObjectWithDefault -Name 'Message' -Value ''),
($_ | SelectObjectWithDefault -Name 'Exception' -Value '') |
? { -not [String]::IsNullOrEmpty($_) } |
Select -First 1
$delimiter = ''
if ((-not [String]::IsNullOrEmpty($header)) -and
(-not [String]::IsNullOrEmpty($shortException)))
{ $delimiter = ' [<<==>>] ' }
return "$($header)$($delimiter)Exception: $($shortException)"
}
}
function WriteDocumentation {
$currentContext = $psake.context.Peek()
if ($currentContext.tasks.default) {
$defaultTaskDependencies = $currentContext.tasks.default.DependsOn
} else {
$defaultTaskDependencies = @()
}
$currentContext.tasks.Keys | foreach-object {
if ($_ -eq "default") {
return
}
$task = $currentContext.tasks.$_
new-object PSObject -property @{
Name = $task.Name;
Alias = $task.Alias;
Description = $task.Description;
"Depends On" = $task.DependsOn -join ", "
Default = if ($defaultTaskDependencies -contains $task.Name) { $true }
}
} | sort 'Name' | format-table -autoSize -wrap -property Name,Alias,"Depends On",Default,Description
}
function WriteTaskTimeSummary($invokePsakeDuration) {
"-" * 70
"Build Time Report"
"-" * 70
$list = @()
$currentContext = $psake.context.Peek()
while ($currentContext.executedTasks.Count -gt 0) {
$taskKey = $currentContext.executedTasks.Pop()
$task = $currentContext.tasks.$taskKey
if ($taskKey -eq "default") {
continue
}
$list += new-object PSObject -property @{
Name = $task.Name;
Duration = $task.Duration
}
}
[Array]::Reverse($list)
$list += new-object PSObject -property @{
Name = "Total:";
Duration = $invokePsakeDuration
}
# using "out-string | where-object" to filter out the blank line that format-table prepends
$list | format-table -autoSize -property Name,Duration | out-string -stream | where-object { $_ }
}
DATA msgs {
convertfrom-stringdata @'
error_invalid_task_name = Task name should not be null or empty string.
error_task_name_does_not_exist = Task {0} does not exist.
error_circular_reference = Circular reference found for task {0}.
error_missing_action_parameter = Action parameter must be specified when using PreAction or PostAction parameters for task {0}.
error_corrupt_callstack = Call stack was corrupt. Expected {0}, but got {1}.
error_invalid_framework = Invalid .NET Framework version, {0} specified.
error_unknown_framework = Unknown .NET Framework version, {0} specified in {1}.
error_unknown_pointersize = Unknown pointer size ({0}) returned from System.IntPtr.
error_unknown_bitnesspart = Unknown .NET Framework bitness, {0}, specified in {1}.
error_no_framework_install_dir_found = No .NET Framework installation directory found at {0}.
error_bad_command = Error executing command {0}.
error_default_task_cannot_have_action = 'default' task cannot specify an action.
error_duplicate_task_name = Task {0} has already been defined.
error_duplicate_alias_name = Alias {0} has already been defined.
error_invalid_include_path = Unable to include {0}. File not found.
error_build_file_not_found = Could not find the build file {0}.
error_no_default_task = 'default' task required.
error_loading_module = Error loading module {0}.
warning_deprecated_framework_variable = Warning: Using global variable $framework to set .NET framework version used is deprecated. Instead use Framework function or configuration file psake-config.ps1.
required_variable_not_set = Variable {0} must be set to run task {1}.
postcondition_failed = Postcondition failed for task {0}.
precondition_was_false = Precondition was false, not executing task {0}.
continue_on_error = Error in task {0}. {1}
build_success = Build Succeeded!
'@
}
import-localizeddata -bindingvariable msgs -erroraction silentlycontinue
$script:psake = @{}
$psake.version = "4.3.2" # contains the current version of psake
$psake.context = new-object system.collections.stack # holds onto the current state of all variables
$psake.run_by_psake_build_tester = $false # indicates that build is being run by psake-BuildTester
$psake.config_default = new-object psobject -property @{
buildFileName = "default.ps1";
framework = "4.0";
taskNameFormat = "Executing {0}";
verboseError = $false;
coloredOutput = $true;
modules = $null;
moduleScope = "";
} # contains default configuration, can be overriden in psake-config.ps1 in directory with psake.psm1 or in directory with current build script
$psake.build_success = $false # indicates that the current build was successful
$psake.build_script_file = $null # contains a System.IO.FileInfo for the current build script
$psake.build_script_dir = "" # contains a string with fully-qualified path to current build script
LoadConfiguration
export-modulemember -function Invoke-psake, Invoke-Task, Task, Properties, Include, FormatTaskName, TaskSetup, TaskTearDown, Framework, Assert, Exec -variable psake

1
old/build/tools/NUnitHTMLReportGenerator.exe.REMOVED.git-id

@ -1 +0,0 @@
75c3885b6db49741cd7c7efe3bda996c2fae5ae7

7
old/build/tools/NUnitHTMLReportGenerator.exe.config

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="utf-8" ?>
<!-- https://github.com/JatechUK/NUnit-HTML-Report-Generator -->
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
</configuration>

BIN
old/build/tools/docu/Interop.SparkLanguagePackageLib.dll

Binary file not shown.

1
old/build/tools/docu/Spark.dll.REMOVED.git-id

@ -1 +0,0 @@
d3fa096caf69385df6771dd68981b46e5e9193e1

BIN
old/build/tools/docu/SparkLanguage.dll

Binary file not shown.

1
old/build/tools/docu/StructureMap.dll.REMOVED.git-id

@ -1 +0,0 @@
a8e84e553b884b6bd2ea01cf8ba12631b6788b1e

1
old/build/tools/docu/docu.exe.REMOVED.git-id

@ -1 +0,0 @@
76e95d1e37dd5508a872071da057a2a74d14a833

3
old/build/tools/docu/docu.exe.config

@ -1,3 +0,0 @@
<?xml version="1.0"?>
<configuration>
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/></startup></configuration>

82
old/build/tools/docu/templates/!namespace/!type.htm.spark

@ -1,82 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<title>${h(Type.PrettyName)} - ${WriteProductName(Assemblies[0])} Documentation</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link type="text/css" rel="stylesheet" href="../main.css" />
<script type="text/javascript" src="../js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="../js/jquery.scrollTo-min.js"></script>
<script type="text/javascript" src="../js/navigation.js"></script>
<script type="text/javascript" src="../js/example.js"></script>
</head>
<body>
<header><h1>${WriteProductName(Assemblies[0])} : API Documentation</h1>
</header>
<namespaces />
<types />
<article>
<header>
<p class="class"><strong>Type</strong> ${h(Type.PrettyName)}</p>
</header>
<section>
<header>
<p><strong>Namespace</strong> ${Namespace.Name}</p>
<p if="Type.ParentType != null && Type.ParentType.PrettyName != 'object'"><strong>Parent</strong> ${Format(Type.ParentType)}</p>
<p if="Type.Interfaces.Count > 0"><strong>Interfaces</strong> ${WriteInterfaces(Type.Interfaces)}</p>
</header>
<div class="sub-header">
<if condition="(Type.Summary != null && Type.Summary.Children.Count() > 0) || (Type.Remarks != null && Type.Remarks.Children.Count() > 0)">
<div id="summary">
<comment content="Type.Summary" />
<remarks content="Type.Remarks" />
<example content="Type.Example" />
</div>
</if>
<if condition="Type.Events.Count > 0">
<h3 class="section">Events</h3>
<ul>
<li each="var ev in Type.Events">${Format(ev)}</li>
</ul>
</if>
<if condition="Type.Methods.Count > 0">
<h3 class="section">Methods</h3>
<ul>
<li each="var method in Type.Methods">${Format(method)}</li>
</ul>
</if>
<if condition="Type.Properties.Count > 0">
<h3 class="section">Properties</h3>
<ul>
<li each="var property in Type.Properties">${Format(property)}</li>
</ul>
</if>
<if condition="Type.Fields.Count > 0">
<h3 class="section">Fields</h3>
<ul>
<li each="var field in Type.Fields">${Format(field)}</li>
</ul>
</if>
</div>
<events events="Type.Events" title="'Events'" />
<var publicInstanceMethods="Type.Methods.Where(x => x.IsPublic && !x.IsStatic)" />
<methods methods="publicInstanceMethods" title="'Public instance methods'" />
<var publicStaticMethods="Type.Methods.Where(x => x.IsPublic && x.IsStatic)" />
<methods methods="publicStaticMethods" title="'Public static methods'" />
<properties properties="Type.Properties" title="'Public properties'" />
<fields fields="Type.Fields" title="'Public fields'" />
</section>
</article>
<use file="../_common_footer" />
</body>
</html>

1
old/build/tools/docu/templates/!namespace/_comment.spark

@ -1 +0,0 @@
${Format(content)}

12
old/build/tools/docu/templates/!namespace/_events.spark

@ -1,12 +0,0 @@
<if condition="events.Count() > 0">
<h3 class="section">${title}</h3>
<div id="${ev.Name}" class="method" each="var ev in events">
<h4><strong>${h(ev.Name)}</strong></h4>
<div class="content">
<comment content="ev.Summary" />
<remarks content="ev.Remarks" />
<example content="ev.Example" />
</div>
</div>
</if>

4
old/build/tools/docu/templates/!namespace/_example.spark

@ -1,4 +0,0 @@
<div class="example" if="content != null && content.Children.Count() > 0">
<a href="javascript:void(0)">Show Example</a>
<pre>${Format(content)}</pre>
</div>

19
old/build/tools/docu/templates/!namespace/_fields.spark

@ -1,19 +0,0 @@
<if condition="fields.Count() > 0">
<h3 class="section">${title}</h3>
<div id="${field.Name}" class="method" each="var field in fields">
<h4>${h(field.ReturnType.PrettyName)} <strong>${h(field.Name)}</strong></h4>
<div class="content">
<comment content="field.Summary" />
<remarks content="field.Remarks" />
<table>
<tr>
<td>
<code>return ${Format(field.ReturnType)}</code>
</td>
</tr>
</table>
<example content="field.Example" />
</div>
</div>
</if>

46
old/build/tools/docu/templates/!namespace/_methods.spark

@ -1,46 +0,0 @@
<if condition="methods.Count() > 0">
<h3 class="section">${title}</h3>
<div id="${method.Name}" class="method" each="var method in methods">
<h4>
${Format(method.ReturnType)} <strong>${h(method.PrettyName)}</strong>(${OutputMethodParams(method)})
</h4>
<div class="content">
<comment content="method.Summary" />
<remarks content="method.Remarks" />
<var hasReturn="method.ReturnType.PrettyName != 'void'" />
<var hasParams="method.Parameters.Any(x => x.HasDocumentation)" />
<div class="parameters" if="hasParams">
<h5>Parameters</h5>
<dl>
<for each="var param in method.Parameters">
<dt>
<code>${Format(param.Reference)}</code> ${param.Name}
</dt>
<dd if="!param.Summary.IsEmpty">
<comment content="param.Summary" />
</dd>
</for>
</dl>
</div>
<div class="return" if="!method.Returns.IsEmpty">
<h5>Returns</h5>
<dl>
<dt>
<code>${Format(method.ReturnType)}</code>
</dt>
<dd>
<comment content="method.Returns" />
</dd>
</dl>
</div>
<value content="method.Value" />
<example content="method.Example" />
</div>
</div>
</if>

14
old/build/tools/docu/templates/!namespace/_namespaces.spark

@ -1,14 +0,0 @@
<nav id="namespaces">
<h2 class="fixed">Namespaces</h2>
<div class="scroll">
<ul>
<li each="var ns in Namespaces">
<if condition="ns == Namespace">
${Format(ns, class => "current")}
<else />
${Format(ns)}
</if>
</li>
</ul>
</div>
</nav>

27
old/build/tools/docu/templates/!namespace/_properties.spark

@ -1,27 +0,0 @@
<if condition="properties.Count() > 0">
<h3 class="section">${title}</h3>
<div id="${property.Name}" class="method" each="var property in properties">
<h4>
${Format(property.ReturnType)} <strong>${h(property.Name)}</strong> <if condition="property.HasGet">get;</if> <if condition="property.HasSet">set;</if>
</h4>
<div class="content">
<comment content="property.Summary" />
<remarks content="property.Remarks" />
<div class="return" if="property.ReturnType.HasDocumentation">
<h5>Property type</h5>
<dl>
<dt>
<code>${Format(property.ReturnType)}</code>
</dt>
<dd>
<comment content="property.ReturnType.Summary" />
</dd>
</dl>
</div>
<value content="property.Value" />
<example content="property.Example" />
</div>
</div>
</if>

3
old/build/tools/docu/templates/!namespace/_remarks.spark

@ -1,3 +0,0 @@
<blockquote class="remarks" if="content != null && content.Children.Count() > 0">
${Format(content)}
</blockquote>

14
old/build/tools/docu/templates/!namespace/_types.spark

@ -1,14 +0,0 @@
<nav id="types">
<h2 class="fixed">Types in ${Namespace.PrettyName}</h2>
<div class="scroll">
<ul>
<li each="var type in Namespace.Types">
<if condition="type == Type">
${Format(type, class => "current")}
<else />
${Format(type)}
</if>
</li>
</ul>
</div>
</nav>

3
old/build/tools/docu/templates/!namespace/_value.spark

@ -1,3 +0,0 @@
<blockquote class="value" if="content.Children.Count() > 0">
<strong>Value: </strong>${Format(content)}
</blockquote>

49
old/build/tools/docu/templates/!namespace/index.htm.spark

@ -1,49 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<title>${Namespace.Name} - ${WriteProductName(Assemblies[0])} Documentation</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link type="text/css" rel="stylesheet" href="../main.css" />
<script type="text/javascript" src="../js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="../js/jquery.scrollTo-min.js"></script>
<script type="text/javascript" src="../js/navigation.js"></script>
</head>
<body>
<header><h1>${WriteProductName(Assemblies[0])} : API Documentation</h1>
</header>
<namespaces />
<types />
<article>
<header>
<p class="class"><strong>Namespace</strong> ${Namespace.Name}</p>
</header>
<section>
<div class="sub-header">
<if condition="Namespace.HasClasses">
<h3 class="section">Classes</h3>
<ul>
<for each="var type in Namespace.Classes">
<li>${Format(type)}</li>
</for>
</ul>
</if>
<if condition="Namespace.HasInterfaces">
<h3 class="section">Interfaces</h3>
<ul>
<for each="var type in Namespace.Interfaces">
<li>${Format(type)}</li>
</for>
</ul>
</if>
<p if="!Namespace.HasTypes">This namespace is empty.</p>
</div>
</section>
</article>
<use file="../_common_footer" />
</body>
</html>

6
old/build/tools/docu/templates/_common_footer.spark

@ -1,6 +0,0 @@
<footer>
<span id="version">Built from v${WriteVersion(Assemblies[0])} of ${WriteAssemblyTitle(Assemblies[0])}</span>
<span id="docu-link">
Generated by <a href="http://docu.jagregory.com">docu</a>
</span>
</footer>

8
old/build/tools/docu/templates/_namespaces.spark

@ -1,8 +0,0 @@
<nav id="namespaces">
<h2 class="fixed">Namespaces</h2>
<div class="scroll">
<ul>
<li each="var ns in Namespaces">${Format(ns)}</li>
</ul>
</div>
</nav>

10
old/build/tools/docu/templates/_types.spark

@ -1,10 +0,0 @@
<nav id="types">
<h2 class="fixed">All Types</h2>
<div class="scroll">
<ul>
<for each="var ns in Namespaces">
<li each="var type in ns.Types">${Format(type)}</li>
</for>
</ul>
</div>
</nav>

23
old/build/tools/docu/templates/index.htm.spark

@ -1,23 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<title>${WriteProductName(Assemblies[0])} API Documentation</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link type="text/css" rel="stylesheet" href="main.css" />
</head>
<body>
<header><h1>${WriteProductName(Assemblies[0])} : API Documentation</h1>
</header>
<namespaces />
<types />
<article>
<header>
<p class="class">${WriteProductName(Assemblies[0])} Documentation</p>
</header>
</article>
<use file="_common_footer" />
</body>
</html>

21
old/build/tools/docu/templates/js/example.js

@ -1,21 +0,0 @@
$(document).ready(function() {
$('div.example').each(function(i, div) {
var a = $('a', div);
var pre = $('pre', div);
a.pre = pre;
a.preVisible = false;
pre.hide();
a.click(function() {
if (a.preVisible) {
a.pre.hide();
a.text('Show Example');
a.preVisible = false;
} else {
a.pre.show();
a.text('Hide Example');
a.preVisible = true;
}
});
});
});

19
old/build/tools/docu/templates/js/jquery-1.3.2.min.js

File diff suppressed because one or more lines are too long

11
old/build/tools/docu/templates/js/jquery.scrollTo-min.js

@ -1,11 +0,0 @@
/**
* jQuery.ScrollTo - Easy element scrolling using jQuery.
* Copyright (c) 2007-2009 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com
* Dual licensed under MIT and GPL.
* Date: 5/25/2009
* @author Ariel Flesler
* @version 1.4.2
*
* http://flesler.blogspot.com/2007/10/jqueryscrollto.html
*/
;(function(d){var k=d.scrollTo=function(a,i,e){d(window).scrollTo(a,i,e)};k.defaults={axis:'xy',duration:parseFloat(d.fn.jquery)>=1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);

11
old/build/tools/docu/templates/js/navigation.js

@ -1,11 +0,0 @@
$(document).ready(function() {
var scroll = function(selector) {
var currentItem = $(selector + ' .current');
if (currentItem)
$(selector + ' div.scroll').scrollTo(currentItem);
};
scroll('#namespaces');
scroll('#types');
});

263
old/build/tools/docu/templates/main.css

@ -1,263 +0,0 @@
/* HTML5 ? Boilerplate */
html, body, div, span, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
abbr, address, cite, code, del, dfn, em, img, ins, kbd, q, samp,
small, strong, sub, sup, var, b, i, dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, figcaption, figure,
footer, header, hgroup, menu, nav, section, summary,
time, mark, audio, video {
margin: 0;
padding: 0;
border: 0;
font-size: 100%;
font: inherit;
vertical-align: baseline;
}
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
display: block;
}
blockquote, q { quotes: none; }
blockquote:before, blockquote:after,
q:before, q:after { content: ""; content: none; }
ins { background-color: #ff9; color: #000; text-decoration: none; }
mark { background-color: #ff9; color: #000; font-style: italic; font-weight: bold; }
del { text-decoration: line-through; }
abbr[title], dfn[title] { border-bottom: 1px dotted; cursor: help; }
table { border-collapse: collapse; border-spacing: 0; }
hr { display: block; height: 1px; border: 0; border-top: 1px solid #ccc; margin: 1em 0; padding: 0; }
input, select { vertical-align: middle; }
body { font:13px/1.231 sans-serif; }
select, input, textarea, button { font:99% sans-serif; }
pre, code, kbd, samp { font-family: monospace, sans-serif; }
html { overflow-y: scroll; }
a:hover, a:active { outline: none; }
ul, ol { margin-left: 2em; }
ol { list-style-type: decimal; }
nav ul, nav li { margin: 0; list-style:none; list-style-image: none; }
small { font-size: 85%; }
strong, th { font-weight: bold; }
td { vertical-align: top; }
sub, sup { font-size: 75%; line-height: 0; position: relative; }
sup { top: -0.5em; }
sub { bottom: -0.25em; }
pre { white-space: pre; white-space: pre-wrap; word-wrap: break-word; padding: 15px; }
textarea { overflow: auto; }
.ie6 legend, .ie7 legend { margin-left: -7px; }
input[type="radio"] { vertical-align: text-bottom; }
input[type="checkbox"] { vertical-align: bottom; }
.ie7 input[type="checkbox"] { vertical-align: baseline; }
.ie6 input { vertical-align: text-bottom; }
label, input[type="button"], input[type="submit"], input[type="image"], button { cursor: pointer; }
button, input, select, textarea { margin: 0; }
input:valid, textarea:valid { }
input:invalid, textarea:invalid { -moz-box-shadow: 0px 0px 5px red; -webkit-box-shadow: 0px 0px 5px red; }
.no-boxshadow input:invalid, .no-boxshadow textarea:invalid { background-color: #f0dddd; }
::-moz-selection{ background: #FF5E99; color:#fff; }
::selection { background:#FF5E99; color:#fff; }
a:link { -webkit-tap-highlight-color: #FF5E99; }
button { width: auto; overflow: visible; }
.ie7 img { -ms-interpolation-mode: bicubic; }
h1, h2, h3, h4, h5, h6 { font-weight: bold; }
a, a:active, a:visited { color: #607890; }
a:hover { color: #036; }
/**
* Primary styles
*
* Author: Dylan Beattie (dylan@dylanbeattie.net)
*/
body > header {
position: absolute;
left: 8px;
right: 8px;
top: 8px;
height: 16px;
padding: 4px;
border: 1px solid #333333;
}
body > header > span#project-link {
position: absolute;
right: 4px;
top: 4px;
}
body {
background-color: #999999;
}
nav {
padding: 0px;
}
div.scroll {
padding: 4px;
overflow: auto;
position: absolute;
top: 24px;
bottom: 0px;
left: 0px;
right: 0px;
background-color: #fff;
}
div.scroll ul li {
padding: 2px 0px;
}
div.scroll ul li a {
text-decoration: none;
}
nav#namespaces {
position: absolute;
top: 42px;
left: 8px;
bottom: 8px;
width: 384px;
overflow: hidden;
}
nav#types {
position: absolute;
top: 42px;
right: 8px;
left: 400px;
height: 204px;
background-color: #fff;
overflow: hidden;
}
article {
position: absolute;
left: 400px;
top: 256px;
bottom: 40px;
right: 8px;
background-color: #fff;
}
footer {
position: absolute;
left: 400px;
bottom: 8px;
height: 16px;
right: 8px;
background-color: #aaaaaa;
padding: 4px;
font-size: 80%;
}
header {
background-color: #cccccc;
}
header p {
padding: 4px;
}
nav h2, header p.class {
background-color: #333333;
padding: 4px;
color: #fff;
}
article section {
position: absolute;
top: 24px;
bottom: 0px;
left: 0px;
right: 0px;
overflow:auto;
}
section ul li {
margin: 4px 0px;
}
article section header p { margin: 0px; }
article section h3, article section p {
padding: 4px;
margin: 4px 0px;
}
article section h3 {
font-size: 120%;
}
div.method {
padding: 4px 4px 4px 16px;
}
div#summary {
padding: 4px;
}
div.method div.content {
margin: 8px;
}
footer span#docu-link {
position: absolute;
right: 4px;
}
code {
font-family: Consolas, Courier, monospaced;
font-weight: normal;
}
h5 {
margin: 8px 0px;
}
dl dt { width: 180px; float: left; }
dl dd { margin-left: 180px; }
.ir { display: block; text-indent: -999em; overflow: hidden; background-repeat: no-repeat; text-align: left; direction: ltr; }
.hidden { display: none; visibility: hidden; }
.visuallyhidden { border: 0; clip: rect(0 0 0 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; }
.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus { clip: auto; height: auto; margin: 0; overflow: visible; position: static; width: auto; }
.invisible { visibility: hidden; }
.clearfix:before, .clearfix:after { content: "\0020"; display: block; height: 0; overflow: hidden; }
.clearfix:after { clear: both; }
.clearfix { zoom: 1; }
@media all and (orientation:portrait) {
}
@media all and (orientation:landscape) {
}
@media screen and (max-device-width: 480px) {
/* html { -webkit-text-size-adjust:none; -ms-text-size-adjust:none; } */
}
@media print {
* { background: transparent !important; color: black !important; text-shadow: none !important; filter:none !important;
-ms-filter: none !important; }
a, a:visited { color: #444 !important; text-decoration: underline; }
a[href]:after { content: " (" attr(href) ")"; }
abbr[title]:after { content: " (" attr(title) ")"; }
.ir a:after, a[href^="javascript:"]:after, a[href^="#"]:after { content: ""; }
pre, blockquote { border: 1px solid #999; page-break-inside: avoid; }
thead { display: table-header-group; }
tr, img { page-break-inside: avoid; }
@page { margin: 0.5cm; }
p, h2, h3 { orphans: 3; widows: 3; }
h2, h3{ page-break-after: avoid; }
}

1
old/build/tools/doxygen/doxygen.exe.REMOVED.git-id

@ -1 +0,0 @@
e3cd94630633d09a5360ed77a721700f36ce2ec4

1
old/build/tools/doxygen/doxyindexer.exe.REMOVED.git-id

@ -1 +0,0 @@
cf2127aaa212a8eee4938f3b7fd3a09151eacbce

1
old/build/tools/doxygen/doxysearch.cgi.REMOVED.git-id

@ -1 +0,0 @@
0621db7f369243429e07a6fcd66833db3a83c16e

6
old/src/.nuget/NuGet.Config

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<solution>
<add key="disableSourceControlIntegration" value="true" />
</solution>
</configuration>

1
old/src/.nuget/NuGet.exe.REMOVED.git-id

@ -1 +0,0 @@
3ffdd33c6106bb292523c979289efb2b30220df5

136
old/src/.nuget/NuGet.targets

@ -1,136 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">$(MSBuildProjectDirectory)\..\</SolutionDir>
<!-- Enable the restore command to run before builds -->
<RestorePackages Condition=" '$(RestorePackages)' == '' ">false</RestorePackages>
<!-- Property that enables building a package from a project -->
<BuildPackage Condition=" '$(BuildPackage)' == '' ">false</BuildPackage>
<!-- Determines if package restore consent is required to restore packages -->
<RequireRestoreConsent Condition=" '$(RequireRestoreConsent)' != 'false' ">true</RequireRestoreConsent>
<!-- Download NuGet.exe if it does not already exist -->
<DownloadNuGetExe Condition=" '$(DownloadNuGetExe)' == '' ">false</DownloadNuGetExe>
</PropertyGroup>
<ItemGroup Condition=" '$(PackageSources)' == '' ">
<!-- Package sources used to restore packages. By default, registered sources under %APPDATA%\NuGet\NuGet.Config will be used -->
<!-- The official NuGet package source (https://www.nuget.org/api/v2/) will be excluded if package sources are specified and it does not appear in the list -->
<!--
<PackageSource Include="https://www.nuget.org/api/v2/" />
<PackageSource Include="https://my-nuget-source/nuget/" />
-->
</ItemGroup>
<PropertyGroup Condition=" '$(OS)' == 'Windows_NT'">
<!-- Windows specific commands -->
<NuGetToolsPath>$([System.IO.Path]::Combine($(SolutionDir), ".nuget"))</NuGetToolsPath>
<PackagesConfig>$([System.IO.Path]::Combine($(ProjectDir), "packages.config"))</PackagesConfig>
</PropertyGroup>
<PropertyGroup Condition=" '$(OS)' != 'Windows_NT'">
<!-- We need to launch nuget.exe with the mono command if we're not on windows -->
<NuGetToolsPath>$(SolutionDir).nuget</NuGetToolsPath>
<PackagesConfig>packages.config</PackagesConfig>
</PropertyGroup>
<PropertyGroup>
<!-- NuGet command -->
<NuGetExePath Condition=" '$(NuGetExePath)' == '' ">$(NuGetToolsPath)\NuGet.exe</NuGetExePath>
<PackageSources Condition=" $(PackageSources) == '' ">@(PackageSource)</PackageSources>
<NuGetCommand Condition=" '$(OS)' == 'Windows_NT'">"$(NuGetExePath)"</NuGetCommand>
<NuGetCommand Condition=" '$(OS)' != 'Windows_NT' ">mono --runtime=v4.0.30319 $(NuGetExePath)</NuGetCommand>
<PackageOutputDir Condition="$(PackageOutputDir) == ''">$(TargetDir.Trim('\\'))</PackageOutputDir>
<RequireConsentSwitch Condition=" $(RequireRestoreConsent) == 'true' ">-RequireConsent</RequireConsentSwitch>
<NonInteractiveSwitch Condition=" '$(VisualStudioVersion)' != '' AND '$(OS)' == 'Windows_NT' ">-NonInteractive</NonInteractiveSwitch>
<PaddedSolutionDir Condition=" '$(OS)' == 'Windows_NT'">"$(SolutionDir) "</PaddedSolutionDir>
<PaddedSolutionDir Condition=" '$(OS)' != 'Windows_NT' ">"$(SolutionDir)"</PaddedSolutionDir>
<!-- Commands -->
<RestoreCommand>$(NuGetCommand) install "$(PackagesConfig)" -source "$(PackageSources)" $(NonInteractiveSwitch) $(RequireConsentSwitch) -solutionDir $(PaddedSolutionDir)</RestoreCommand>
<BuildCommand>$(NuGetCommand) pack "$(ProjectPath)" -Properties "Configuration=$(Configuration);Platform=$(Platform)" $(NonInteractiveSwitch) -OutputDirectory "$(PackageOutputDir)" -symbols</BuildCommand>
<!-- We need to ensure packages are restored prior to assembly resolve -->
<BuildDependsOn Condition="$(RestorePackages) == 'true'">
RestorePackages;
$(BuildDependsOn);
</BuildDependsOn>
<!-- Make the build depend on restore packages -->
<BuildDependsOn Condition="$(BuildPackage) == 'true'">
$(BuildDependsOn);
BuildPackage;
</BuildDependsOn>
</PropertyGroup>
<Target Name="CheckPrerequisites">
<!-- Raise an error if we're unable to locate nuget.exe -->
<Error Condition="'$(DownloadNuGetExe)' != 'true' AND !Exists('$(NuGetExePath)')" Text="Unable to locate '$(NuGetExePath)'" />
<!--
Take advantage of MsBuild's build dependency tracking to make sure that we only ever download nuget.exe once.
This effectively acts as a lock that makes sure that the download operation will only happen once and all
parallel builds will have to wait for it to complete.
-->
<MsBuild Targets="_DownloadNuGet" Projects="$(MSBuildThisFileFullPath)" Properties="Configuration=NOT_IMPORTANT;DownloadNuGetExe=$(DownloadNuGetExe)" />
</Target>
<Target Name="_DownloadNuGet">
<DownloadNuGet OutputFilename="$(NuGetExePath)" Condition=" '$(DownloadNuGetExe)' == 'true' AND !Exists('$(NuGetExePath)')" />
</Target>
<Target Name="RestorePackages" DependsOnTargets="CheckPrerequisites">
<Exec Command="$(RestoreCommand)"
Condition="'$(OS)' != 'Windows_NT' And Exists('$(PackagesConfig)')" />
<Exec Command="$(RestoreCommand)"
LogStandardErrorAsError="true"
Condition="'$(OS)' == 'Windows_NT' And Exists('$(PackagesConfig)')" />
</Target>
<Target Name="BuildPackage" DependsOnTargets="CheckPrerequisites">
<Exec Command="$(BuildCommand)"
Condition=" '$(OS)' != 'Windows_NT' " />
<Exec Command="$(BuildCommand)"
LogStandardErrorAsError="true"
Condition=" '$(OS)' == 'Windows_NT' " />
</Target>
<UsingTask TaskName="DownloadNuGet" TaskFactory="CodeTaskFactory" AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll">
<ParameterGroup>
<OutputFilename ParameterType="System.String" Required="true" />
</ParameterGroup>
<Task>
<Reference Include="System.Core" />
<Using Namespace="System" />
<Using Namespace="System.IO" />
<Using Namespace="System.Net" />
<Using Namespace="Microsoft.Build.Framework" />
<Using Namespace="Microsoft.Build.Utilities" />
<Code Type="Fragment" Language="cs">
<![CDATA[
try {
OutputFilename = Path.GetFullPath(OutputFilename);
Log.LogMessage("Downloading latest version of NuGet.exe...");
WebClient webClient = new WebClient();
webClient.DownloadFile("https://www.nuget.org/nuget.exe", OutputFilename);
return true;
}
catch (Exception ex) {
Log.LogErrorFromException(ex);
return false;
}
]]>
</Code>
</Task>
</UsingTask>
</Project>

7
old/src/.nuget/packages.config

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="coveralls.io" version="1.3.2" />
<package id="NUnit.Runners" version="2.6.3" />
<package id="OpenCover" version="4.5.3809-rc94" />
<package id="ReportGenerator" version="1.9.1.0" />
</packages>

6
old/src/ImageProcessor.Playground/App.config

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5"/>
</startup>
</configuration>

87
old/src/ImageProcessor.Playground/ImageProcessor.Playground.csproj

@ -1,87 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{7BF5274B-56A7-4B62-8105-E9BDF25BAFE7}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>ImageProcessor.PlayGround</RootNamespace>
<AssemblyName>ImageProcessor.PlayGround</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<TargetFrameworkProfile>
</TargetFrameworkProfile>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup>
<StartupObject />
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Drawing" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Plugins\ImageProcessor.Web\ImageProcessor.Web.Plugins.AzureBlobCache\ImageProcessor.Web.Plugins.AzureBlobCache.csproj">
<Project>{3c805e4c-d679-43f8-8c43-8909cdb4d4d7}</Project>
<Name>ImageProcessor.Web.Plugins.AzureBlobCache</Name>
</ProjectReference>
<ProjectReference Include="..\ImageProcessor.Web\ImageProcessor.Web.csproj">
<Project>{d011a778-59c8-4bfa-a770-c350216bf161}</Project>
<Name>ImageProcessor.Web</Name>
</ProjectReference>
<ProjectReference Include="..\ImageProcessor\ImageProcessor.csproj">
<Project>{3B5DD734-FB7A-487D-8CE6-55E7AF9AEA7E}</Project>
<Name>ImageProcessor</Name>
</ProjectReference>
<ProjectReference Include="..\Plugins\ImageProcessor\ImageProcessor.Plugins.Cair\ImageProcessor.Plugins.Cair.csproj">
<Project>{c7d1f0dd-cbd6-4127-82b4-51949eff0bf5}</Project>
<Name>ImageProcessor.Plugins.Cair</Name>
</ProjectReference>
<ProjectReference Include="..\Plugins\ImageProcessor\ImageProcessor.Plugins.WebP\ImageProcessor.Plugins.WebP.csproj">
<Project>{2cf69699-959a-44dc-a281-4e2596c25043}</Project>
<Name>ImageProcessor.Plugins.WebP</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

186
old/src/ImageProcessor.Playground/Program.cs

@ -1,186 +0,0 @@
// --------------------------------------------------------------------------------------------------------------------
// <copyright file="Program.cs" company="James South">
// Copyright (c) James South.
// Licensed under the Apache License, Version 2.0.
// </copyright>
// <summary>
// The program.
// </summary>
// --------------------------------------------------------------------------------------------------------------------
namespace ImageProcessor.PlayGround
{
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Linq;
using ImageProcessor;
using ImageProcessor.Configuration;
using ImageProcessor.Imaging;
using ImageProcessor.Imaging.Filters.EdgeDetection;
//using ImageProcessor.Imaging.Filters.ObjectDetection;
using ImageProcessor.Imaging.Filters.Photo;
using ImageProcessor.Imaging.Formats;
using ImageProcessor.Processors;
using ImageProcessor.Web.Caching;
/// <summary>
/// The program.
/// </summary>
public class Program
{
/// <summary>
/// The main routine.
/// </summary>
/// <param name="args">
/// The args.
/// </param>
public static void Main(string[] args)
{
string path = new Uri(System.Reflection.Assembly.GetExecutingAssembly().CodeBase).LocalPath;
// ReSharper disable once AssignNullToNotNullAttribute
string resolvedPath = Path.GetFullPath(Path.Combine(Path.GetDirectoryName(path), @"..\..\images\input"));
DirectoryInfo di = new DirectoryInfo(resolvedPath);
if (!di.Exists)
{
di.Create();
}
// Image mask = Image.FromFile(Path.Combine(resolvedPath, "mask.png"));
// Image overlay = Image.FromFile(Path.Combine(resolvedPath, "imageprocessor.128.png"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "2008.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "stretched.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "mountain.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "blur-test.png"));
// FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "earth_lights_4800.tif"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "gamma-1.0-or-2.2.png"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "gamma_dalai_lama_gray.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "Arc-de-Triomphe-France.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "Martin-Schoeller-Jack-Nicholson-Portrait.jpeg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "night-bridge.png"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "tree.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "blue-balloon.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "test2.png"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "120430.gif"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "rickroll.original.gif"));
//////FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "crop-base-300x200.jpg"));
//FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "cmyk.png"));
//IEnumerable<FileInfo> files = GetFilesByExtensions(di, ".gif");
//IEnumerable<FileInfo> files = GetFilesByExtensions(di, ".png", ".jpg", ".jpeg");
// IEnumerable<FileInfo> files = GetFilesByExtensions(di, ".jpg", ".jpeg", ".jfif");
IEnumerable<FileInfo> files = GetFilesByExtensions(di, ".png");
//IEnumerable<FileInfo> files = GetFilesByExtensions(di, ".gif", ".webp", ".bmp", ".jpg", ".png");
foreach (FileInfo fileInfo in files)
{
if (fileInfo.Name == "test5.jpg")
{
continue;
}
byte[] photoBytes = File.ReadAllBytes(fileInfo.FullName);
Console.WriteLine("Processing: " + fileInfo.Name);
Stopwatch stopwatch = new Stopwatch();
stopwatch.Start();
// ImageProcessor
using (MemoryStream inStream = new MemoryStream(photoBytes))
{
using (ImageFactory imageFactory = new ImageFactory(true, true))
{
Size size = new Size(1920, 1920);
//CropLayer cropLayer = new CropLayer(20, 20, 20, 20, ImageProcessor.Imaging.CropMode.Percentage);
ResizeLayer layer = new ResizeLayer(size, ResizeMode.Max, AnchorPosition.Center, false);
// TextLayer textLayer = new TextLayer()
//{
// Text = "هناك حقيقة مثبتة منذ زمن",
// FontColor = Color.White,
// DropShadow = true,
// Vertical = true,
// //RightToLeft = true,
// //Position = new Point(5, 5)
//};
//ContentAwareResizeLayer layer = new ContentAwareResizeLayer(size)
//{
// ConvolutionType = ConvolutionType.Sobel
//};
// Load, resize, set the format and quality and save an image.
imageFactory.Load(inStream)
//.DetectObjects(EmbeddedHaarCascades.FrontFaceDefault)
//.Overlay(new ImageLayer
// {
// Image = overlay,
// Opacity = 50
// })
//.Alpha(50)
//.BackgroundColor(Color.White)
//.Resize(new Size((int)(size.Width * 1.1), 0))
//.ContentAwareResize(layer)
//.Constrain(size)
//.Mask(mask)
//.Format(new PngFormat())
//.BackgroundColor(Color.Cyan)
//.Watermark(textLayer)
//.ReplaceColor(Color.FromArgb(93, 136, 231), Color.FromArgb(94, 134, 78), 50)
//.GaussianSharpen(3)
//.Saturation(20)
//.Resize(size)
.Resize(layer)
// .Resize(new ResizeLayer(size, ResizeMode.Stretch))
//.DetectEdges(new SobelEdgeFilter(), true)
//.DetectEdges(new LaplacianOfGaussianEdgeFilter())
//.GaussianBlur(new GaussianLayer(10, 11))
//.EntropyCrop()
//.Gamma(2.2F)
//.Halftone()
//.RotateBounded(150, false)
//.Crop(cropLayer)
//.Rotate(140)
//.Filter(MatrixFilters.Invert)
//.Brightness(-5)
//.Contrast(50)
//.Filter(MatrixFilters.Comic)
//.Flip()
//.Filter(MatrixFilters.HiSatch)
//.Pixelate(8)
//.GaussianSharpen(10)
//.Format(new PngFormat() { IsIndexed = true })
//.Format(new PngFormat() )
.Save(Path.GetFullPath(Path.Combine(Path.GetDirectoryName(path), @"..\..\images\output", fileInfo.Name)));
//.Save(Path.GetFullPath(Path.Combine(Path.GetDirectoryName(path), @"..\..\images\output", Path.GetFileNameWithoutExtension(fileInfo.Name) + ".png")));
stopwatch.Stop();
}
}
long peakWorkingSet64 = Process.GetCurrentProcess().PeakWorkingSet64;
float mB = peakWorkingSet64 / (float)1024 / 1024;
Console.WriteLine(@"Completed {0} in {1:s\.fff} secs {2}Peak memory usage was {3} bytes or {4} Mb.", fileInfo.Name, stopwatch.Elapsed, Environment.NewLine, peakWorkingSet64.ToString("#,#"), mB);
//Console.WriteLine("Processed: " + fileInfo.Name + " in " + stopwatch.ElapsedMilliseconds + "ms");
}
Console.ReadLine();
}
public static IEnumerable<FileInfo> GetFilesByExtensions(DirectoryInfo dir, params string[] extensions)
{
if (extensions == null)
{
throw new ArgumentNullException("extensions");
}
IEnumerable<FileInfo> files = dir.EnumerateFiles();
return files.Where(f => extensions.Contains(f.Extension, StringComparer.OrdinalIgnoreCase));
}
}
}

36
old/src/ImageProcessor.Playground/Properties/AssemblyInfo.cs

@ -1,36 +0,0 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ImageProcessorConsole")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("ImageProcessorConsole")]
[assembly: AssemblyCopyright("Copyright © 2014")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("ac215639-6e27-4b9c-9ebb-9116c7a5d8a6")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

BIN
old/src/ImageProcessor.Playground/images/input/000.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 B

BIN
old/src/ImageProcessor.Playground/images/input/001.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 B

1
old/src/ImageProcessor.Playground/images/input/120430.gif.REMOVED.git-id

@ -1 +0,0 @@
56ba9f614f44f7c905481f35e7609cb93e8fe98c

1
old/src/ImageProcessor.Playground/images/input/1aaa.jpg.REMOVED.git-id

@ -1 +0,0 @@
68e14cae5c31c58b8b66d26bca6eb67c79ecd203

1
old/src/ImageProcessor.Playground/images/input/2006-citybus.jpg.REMOVED.git-id

@ -1 +0,0 @@
7f6786517fa67c9dfccac831e8491e4d08866d24

1
old/src/ImageProcessor.Playground/images/input/2008.jpg.REMOVED.git-id

@ -1 +0,0 @@
7eb554b7681119b1170b70f1c1c2fc0de28a60ac

1
old/src/ImageProcessor.Playground/images/input/2012-citybus.jpg.REMOVED.git-id

@ -1 +0,0 @@
8d39e89104598b85035a2c29592b847edcfdb8ac

BIN
old/src/ImageProcessor.Playground/images/input/4.sm.webp

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

1
old/src/ImageProcessor.Playground/images/input/Arc-de-Triomphe-France.jpg.REMOVED.git-id

@ -1 +0,0 @@
ff6cd6bf1cd388e8933071ec36880c33d1bc08f2

1
old/src/ImageProcessor.Playground/images/input/Bikesgray.png.REMOVED.git-id

@ -1 +0,0 @@
93b93eade2c7697a0a8fe9363d493a8a59de245a

1
old/src/ImageProcessor.Playground/images/input/Calliphora_sp_Portrait.jpg.REMOVED.git-id

@ -1 +0,0 @@
5d446f64d0636f6ad7e9f82625eeff89ef394fe2

1
old/src/ImageProcessor.Playground/images/input/IC580196.jpg.REMOVED.git-id

@ -1 +0,0 @@
9ab3fa52dd238ee4caffb47c82929f4079dc38d3

1
old/src/ImageProcessor.Playground/images/input/Martin-Schoeller-Jack-Nicholson-Portrait.jpeg.REMOVED.git-id

@ -1 +0,0 @@
ea3907f002c75115c976edb47c9a8ba28e76ad9a

BIN
old/src/ImageProcessor.Playground/images/input/PIA11667_modest.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

1
old/src/ImageProcessor.Playground/images/input/Tl4Yb.gif.REMOVED.git-id

@ -1 +0,0 @@
d5f9ac17c265d12d9d08f8bbeaf3ff13b54b149a

BIN
old/src/ImageProcessor.Playground/images/input/Turtle.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 54 KiB

1
old/src/ImageProcessor.Playground/images/input/Valve_original_(1).PNG.REMOVED.git-id

@ -1 +0,0 @@
bdff6764fd5c4e3054ba7d8c43cc8c29be0e6f5e

1
old/src/ImageProcessor.Playground/images/input/arc_de_triomphe_paris_france.jpg.REMOVED.git-id

@ -1 +0,0 @@
c679b986c1ccbd9f6f8d72d7e4717f380b923a75

BIN
old/src/ImageProcessor.Playground/images/input/blue-balloon.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 58 KiB

BIN
old/src/ImageProcessor.Playground/images/input/blur-test.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

BIN
old/src/ImageProcessor.Playground/images/input/blur-test.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

1
old/src/ImageProcessor.Playground/images/input/bob_revolutionpro_wilderness_02_2013_72dpi_2000x2000.jpg.REMOVED.git-id

@ -1 +0,0 @@
cfa62bc3b77a7efb16c25218c1381da5d4f36db7

1
old/src/ImageProcessor.Playground/images/input/cat.jpg.REMOVED.git-id

@ -1 +0,0 @@
c704af2c49aa45e35eab9e1b4839edbb7221cc7e

BIN
old/src/ImageProcessor.Playground/images/input/ce1a34f6-52bd-11e4-8164-54281a6247c9.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

BIN
old/src/ImageProcessor.Playground/images/input/circle.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

BIN
old/src/ImageProcessor.Playground/images/input/circle2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

BIN
old/src/ImageProcessor.Playground/images/input/circle3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

1
old/src/ImageProcessor.Playground/images/input/cmyk-test.png.REMOVED.git-id

@ -1 +0,0 @@
b6a165b747788ab89169b1b0ab7a66c1a67eeaee

BIN
old/src/ImageProcessor.Playground/images/input/cmyk.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

1
old/src/ImageProcessor.Playground/images/input/cow_PNG2140.png.REMOVED.git-id

@ -1 +0,0 @@
04b381ec37fffdbffa55d5b02478ad81375eaa4b

BIN
old/src/ImageProcessor.Playground/images/input/crop-base-300x200.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

1
old/src/ImageProcessor.Playground/images/input/earth_lights_4800.tif.REMOVED.git-id

@ -1 +0,0 @@
e44293020be795c40cbb19f2bad7d8589d479fb2

Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save