albacore 2.0.0.rc.18 → 2.0.0.rc.19

Sign up to get free protection for your applications and to get access to all the features.
Files changed (112) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +68 -8
  3. data/albacore.gemspec +1 -1
  4. data/lib/albacore/app_spec.rb +38 -6
  5. data/lib/albacore/app_spec/README.md +4 -0
  6. data/lib/albacore/app_spec/defaults.rb +61 -0
  7. data/lib/albacore/app_spec/iis_site.rb +42 -0
  8. data/lib/albacore/cpack_app_spec.rb +30 -39
  9. data/lib/albacore/version.rb +1 -1
  10. data/resources/installSite.ps1 +50 -0
  11. data/spec/test_appspecs/corp.service/.gitignore +3 -0
  12. data/spec/test_appspecs/corp.service/.nuget/packages.config +4 -0
  13. data/spec/test_appspecs/corp.service/CSharpWeb/.appspec +5 -0
  14. data/spec/test_appspecs/corp.service/CSharpWeb/App_Start/BundleConfig.cs +43 -0
  15. data/spec/test_appspecs/corp.service/CSharpWeb/App_Start/FilterConfig.cs +13 -0
  16. data/spec/test_appspecs/corp.service/CSharpWeb/App_Start/RouteConfig.cs +23 -0
  17. data/spec/test_appspecs/corp.service/CSharpWeb/App_Start/WebApiConfig.cs +19 -0
  18. data/spec/test_appspecs/corp.service/CSharpWeb/CSharpWeb.csproj +264 -0
  19. data/spec/test_appspecs/corp.service/CSharpWeb/Content/Site.css +61 -0
  20. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  21. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
  22. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  23. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  24. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_glass_75_dadada_1x400.png +0 -0
  25. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  26. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  27. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  28. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-icons_222222_256x240.png +0 -0
  29. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-icons_2e83ff_256x240.png +0 -0
  30. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-icons_454545_256x240.png +0 -0
  31. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-icons_888888_256x240.png +0 -0
  32. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/images/ui-icons_cd0a0a_256x240.png +0 -0
  33. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery-ui.css +464 -0
  34. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.accordion.css +19 -0
  35. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.all.css +11 -0
  36. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.autocomplete.css +53 -0
  37. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.base.css +21 -0
  38. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.button.css +38 -0
  39. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.core.css +38 -0
  40. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.datepicker.css +66 -0
  41. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.dialog.css +21 -0
  42. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.progressbar.css +11 -0
  43. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.resizable.css +20 -0
  44. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.selectable.css +10 -0
  45. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.slider.css +24 -0
  46. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.tabs.css +18 -0
  47. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/jquery.ui.theme.css +247 -0
  48. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  49. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
  50. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  51. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  52. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_glass_75_dadada_1x400.png +0 -0
  53. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  54. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  55. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  56. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-icons_222222_256x240.png +0 -0
  57. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-icons_2e83ff_256x240.png +0 -0
  58. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-icons_454545_256x240.png +0 -0
  59. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-icons_888888_256x240.png +0 -0
  60. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/images/ui-icons_cd0a0a_256x240.png +0 -0
  61. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery-ui.min.css +5 -0
  62. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.accordion.min.css +5 -0
  63. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.autocomplete.min.css +5 -0
  64. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.button.min.css +5 -0
  65. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.core.min.css +5 -0
  66. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.datepicker.min.css +5 -0
  67. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.dialog.min.css +5 -0
  68. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.progressbar.min.css +5 -0
  69. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.resizable.min.css +5 -0
  70. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.selectable.min.css +5 -0
  71. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.slider.min.css +5 -0
  72. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.tabs.min.css +5 -0
  73. data/spec/test_appspecs/corp.service/CSharpWeb/Content/themes/base/minified/jquery.ui.theme.min.css +5 -0
  74. data/spec/test_appspecs/corp.service/CSharpWeb/Controllers/HomeController.cs +17 -0
  75. data/spec/test_appspecs/corp.service/CSharpWeb/Global.asax +1 -0
  76. data/spec/test_appspecs/corp.service/CSharpWeb/Global.asax.cs +24 -0
  77. data/spec/test_appspecs/corp.service/CSharpWeb/Properties/AssemblyInfo.cs +35 -0
  78. data/spec/test_appspecs/corp.service/CSharpWeb/Properties/PublishProfiles/local.pubxml +17 -0
  79. data/spec/test_appspecs/corp.service/CSharpWeb/Views/Home/Index.cshtml +8 -0
  80. data/spec/test_appspecs/corp.service/CSharpWeb/Views/Shared/Error.cshtml +17 -0
  81. data/spec/test_appspecs/corp.service/CSharpWeb/Views/Shared/_Layout.cshtml +16 -0
  82. data/spec/test_appspecs/corp.service/CSharpWeb/Views/Web.config +59 -0
  83. data/spec/test_appspecs/corp.service/CSharpWeb/Views/_ViewStart.cshtml +3 -0
  84. data/spec/test_appspecs/corp.service/CSharpWeb/Web.Debug.config +30 -0
  85. data/spec/test_appspecs/corp.service/CSharpWeb/Web.Release.config +31 -0
  86. data/spec/test_appspecs/corp.service/CSharpWeb/Web.config +107 -0
  87. data/spec/test_appspecs/corp.service/CSharpWeb/packages.config +26 -0
  88. data/spec/test_appspecs/corp.service/FSharpWeb/AssemblyInfo.fs +22 -0
  89. data/spec/test_appspecs/corp.service/FSharpWeb/Content/Site.css +42 -0
  90. data/spec/test_appspecs/corp.service/FSharpWeb/Controllers/HomeController.fs +13 -0
  91. data/spec/test_appspecs/corp.service/FSharpWeb/Controllers/ValuesController.fs +23 -0
  92. data/spec/test_appspecs/corp.service/FSharpWeb/FSharpWeb.fsproj +217 -0
  93. data/spec/test_appspecs/corp.service/FSharpWeb/Global.asax +1 -0
  94. data/spec/test_appspecs/corp.service/FSharpWeb/Global.asax.fs +71 -0
  95. data/spec/test_appspecs/corp.service/FSharpWeb/Views/Home/Index.cshtml +10 -0
  96. data/spec/test_appspecs/corp.service/FSharpWeb/Views/Shared/Error.cshtml +5 -0
  97. data/spec/test_appspecs/corp.service/FSharpWeb/Views/Shared/_Layout.cshtml +40 -0
  98. data/spec/test_appspecs/corp.service/FSharpWeb/Views/Web.config +34 -0
  99. data/spec/test_appspecs/corp.service/FSharpWeb/Views/_ViewStart.cshtml +3 -0
  100. data/spec/test_appspecs/corp.service/FSharpWeb/fonts/glyphicons-halflings-regular.eot +0 -0
  101. data/spec/test_appspecs/corp.service/FSharpWeb/fonts/glyphicons-halflings-regular.svg +229 -0
  102. data/spec/test_appspecs/corp.service/FSharpWeb/fonts/glyphicons-halflings-regular.ttf +0 -0
  103. data/spec/test_appspecs/corp.service/FSharpWeb/fonts/glyphicons-halflings-regular.woff +0 -0
  104. data/spec/test_appspecs/corp.service/FSharpWeb/local.pubxml +17 -0
  105. data/spec/test_appspecs/corp.service/FSharpWeb/packages.config +21 -0
  106. data/spec/test_appspecs/corp.service/FSharpWeb/readme.txt +1 -0
  107. data/spec/test_appspecs/corp.service/FSharpWeb/web.config +55 -0
  108. data/spec/test_appspecs/corp.service/Rakefile +13 -2
  109. data/spec/test_appspecs/corp.service/corp.service.svc.sln +18 -1
  110. data/spec/test_appspecs/corp.service/corp.service.svc/.appspec +2 -0
  111. metadata +201 -6
  112. data/spec/test_appspecs/corp.service/corp.service.svc/corp.service.svc.sln +0 -20
@@ -0,0 +1,26 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <packages>
3
+ <package id="EntityFramework" version="5.0.0" targetFramework="net45" />
4
+ <package id="jQuery" version="1.8.2" targetFramework="net45" />
5
+ <package id="jQuery.UI.Combined" version="1.8.24" targetFramework="net45" />
6
+ <package id="jQuery.Validation" version="1.10.0" targetFramework="net45" />
7
+ <package id="knockoutjs" version="2.2.0" targetFramework="net45" />
8
+ <package id="Microsoft.AspNet.Mvc" version="4.0.20710.0" targetFramework="net45" />
9
+ <package id="Microsoft.AspNet.Mvc.FixedDisplayModes" version="1.0.0" targetFramework="net45" />
10
+ <package id="Microsoft.AspNet.Providers.Core" version="1.2" targetFramework="net45" />
11
+ <package id="Microsoft.AspNet.Providers.LocalDB" version="1.1" targetFramework="net45" />
12
+ <package id="Microsoft.AspNet.Razor" version="2.0.20715.0" targetFramework="net45" />
13
+ <package id="Microsoft.AspNet.Web.Optimization" version="1.0.0" targetFramework="net45" />
14
+ <package id="Microsoft.AspNet.WebApi" version="4.0.20710.0" targetFramework="net45" />
15
+ <package id="Microsoft.AspNet.WebApi.Client" version="4.0.20710.0" targetFramework="net45" />
16
+ <package id="Microsoft.AspNet.WebApi.Core" version="4.0.20710.0" targetFramework="net45" />
17
+ <package id="Microsoft.AspNet.WebApi.WebHost" version="4.0.20710.0" targetFramework="net45" />
18
+ <package id="Microsoft.AspNet.WebPages" version="2.0.20710.0" targetFramework="net45" />
19
+ <package id="Microsoft.jQuery.Unobtrusive.Ajax" version="2.0.30116.0" targetFramework="net45" />
20
+ <package id="Microsoft.jQuery.Unobtrusive.Validation" version="2.0.30116.0" targetFramework="net45" />
21
+ <package id="Microsoft.Net.Http" version="2.0.20710.0" targetFramework="net45" />
22
+ <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net45" />
23
+ <package id="Modernizr" version="2.6.2" targetFramework="net45" />
24
+ <package id="Newtonsoft.Json" version="4.5.11" targetFramework="net45" />
25
+ <package id="WebGrease" version="1.3.0" targetFramework="net45" />
26
+ </packages>
@@ -0,0 +1,22 @@
1
+ module FSharpWeb.AssemblyInfo
2
+ open System.Reflection
3
+ open System.Runtime.CompilerServices
4
+
5
+
6
+ [<assembly: AssemblyTitle("FSharpWeb")>]
7
+ [<assembly: AssemblyDescription("")>]
8
+ [<assembly: AssemblyConfiguration("")>]
9
+ [<assembly: AssemblyCompany("")>]
10
+ [<assembly: AssemblyProduct("")>]
11
+ [<assembly: AssemblyCopyright("")>]
12
+ [<assembly: AssemblyTrademark("")>]
13
+
14
+ // The assembly version has the format {Major}.{Minor}.{Build}.{Revision}
15
+
16
+ [<assembly: AssemblyVersion("1.0.0.0")>]
17
+
18
+ //[<assembly: AssemblyDelaySign(false)>]
19
+ //[<assembly: AssemblyKeyFile("")>]
20
+
21
+ ()
22
+
@@ -0,0 +1,42 @@
1
+ body {
2
+ padding-top: 50px;
3
+ padding-bottom: 20px;
4
+ }
5
+
6
+ /* Set padding to keep content from hitting the edges */
7
+ .body-content {
8
+ padding-left: 15px;
9
+ padding-right: 15px;
10
+ }
11
+
12
+ /* Set width on the form input elements since they're 100% wide by default */
13
+ input,
14
+ select,
15
+ textarea {
16
+ max-width: 280px;
17
+ }
18
+
19
+ /* styles for validation helpers */
20
+ .field-validation-error {
21
+ color: #b94a48;
22
+ }
23
+
24
+ .field-validation-valid {
25
+ display: none;
26
+ }
27
+
28
+ input.input-validation-error {
29
+ border: 1px solid #b94a48;
30
+ }
31
+
32
+ input[type="checkbox"].input-validation-error {
33
+ border: 0 none;
34
+ }
35
+
36
+ .validation-summary-errors {
37
+ color: #b94a48;
38
+ }
39
+
40
+ .validation-summary-valid {
41
+ display: none;
42
+ }
@@ -0,0 +1,13 @@
1
+ namespace FSharpWeb.Controllers
2
+
3
+ open System
4
+ open System.Collections.Generic
5
+ open System.Linq
6
+ open System.Web
7
+ open System.Web.Mvc
8
+ open System.Web.Mvc.Ajax
9
+
10
+ type HomeController() =
11
+ inherit Controller()
12
+ member this.Index () = this.View()
13
+
@@ -0,0 +1,23 @@
1
+ namespace FSharpWeb.Controllers
2
+ open System
3
+ open System.Collections.Generic
4
+ open System.Linq
5
+ open System.Net.Http
6
+ open System.Web.Http
7
+
8
+ /// Retrieves values.
9
+ [<RoutePrefix("api2/values")>]
10
+ type ValuesController() =
11
+ inherit ApiController()
12
+ let values = [|"value1";"value2"|]
13
+
14
+ /// Gets all values.
15
+ [<Route("")>]
16
+ member x.Get() = values
17
+
18
+ /// Gets the value with index id.
19
+ [<Route("{id:int}")>]
20
+ member x.Get(id) : IHttpActionResult =
21
+ if id > values.Length - 1 then
22
+ x.BadRequest() :> _
23
+ else x.Ok(values.[id]) :> _
@@ -0,0 +1,217 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3
+ <UsingTask AssemblyFile="$(SolutionDir)\packages\MSBuild.Extension.Pack.1.3.0\tools\net40\MSBuild.ExtensionPack.dll" TaskName="MSBuild.ExtensionPack.FileSystem.File" />
4
+ <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
5
+ <PropertyGroup>
6
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
7
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
8
+ <ProductVersion>10.0.0</ProductVersion>
9
+ <SchemaVersion>2.0</SchemaVersion>
10
+ <ProjectGuid>4c381fcd-d9f3-45d4-88c2-efaf95e6cec3</ProjectGuid>
11
+ <ProjectTypeGuids>{E53F8FEA-EAE0-44A6-8774-FFD645390401};{349C5851-65DF-11DA-9384-00065B846F21};{F2A71F9B-5D33-465A-A702-920D77279786}</ProjectTypeGuids>
12
+ <OutputType>Library</OutputType>
13
+ <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
14
+ <RootNamespace>FSharpWeb</RootNamespace>
15
+ <AssemblyName>FSharpWeb</AssemblyName>
16
+ <UseIISExpress>true</UseIISExpress>
17
+ <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
18
+ <TargetFrameworkProfile />
19
+ <WebGreaseLibPath>..\packages\WebGrease.1.5.2\lib</WebGreaseLibPath>
20
+ <Name>FSharpWeb</Name>
21
+ <NameOfLastUsedPublishProfile>local</NameOfLastUsedPublishProfile>
22
+ </PropertyGroup>
23
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
24
+ <DebugSymbols>true</DebugSymbols>
25
+ <DebugType>full</DebugType>
26
+ <DefineConstants>DEBUG;TRACE</DefineConstants>
27
+ <OutputPath>bin\</OutputPath>
28
+ <ErrorReport>prompt</ErrorReport>
29
+ <PlatformTarget>
30
+ </PlatformTarget>
31
+ <ConsolePause>false</ConsolePause>
32
+ </PropertyGroup>
33
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
34
+ <DebugSymbols>true</DebugSymbols>
35
+ <DebugType>pdbonly</DebugType>
36
+ <DefineConstants>TRACE</DefineConstants>
37
+ <Optimize>true</Optimize>
38
+ <OutputPath>bin\</OutputPath>
39
+ <ErrorReport>prompt</ErrorReport>
40
+ <Tailcalls>true</Tailcalls>
41
+ <ConsolePause>false</ConsolePause>
42
+ <PlatformTarget>
43
+ </PlatformTarget>
44
+ </PropertyGroup>
45
+ <PropertyGroup>
46
+ <MinimumVisualStudioVersion Condition="'$(MinimumVisualStudioVersion)' == ''">11</MinimumVisualStudioVersion>
47
+ </PropertyGroup>
48
+ <PropertyGroup>
49
+ <VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
50
+ <VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
51
+ </PropertyGroup>
52
+ <PropertyGroup>
53
+ <TargetFSharpCoreVersion>4.3.1.0</TargetFSharpCoreVersion>
54
+ <FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
55
+ </PropertyGroup>
56
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '11.0' Or $(OS) != 'Windows_NT'">
57
+ <TargetFSharpCoreVersion>4.3.0.0</TargetFSharpCoreVersion>
58
+ <FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
59
+ </PropertyGroup>
60
+ <Import Project="$(FSharpTargetsPath)" Condition="Exists('$(FSharpTargetsPath)')" />
61
+ <Import Project="$(VSToolsPath)\WebApplications\Microsoft.WebApplication.targets" Condition="'$(VSToolsPath)' != ''" />
62
+ <Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" Condition="false" />
63
+ <ProjectExtensions>
64
+ <MonoDevelop>
65
+ <Properties VerifyCodeBehindFields="True" VerifyCodeBehindEvents="True" xmlns="">
66
+ <XspParameters Port="8080" Address="127.0.0.1" SslMode="None" SslProtocol="Default" KeyType="None" CertFile="" KeyFile="" PasswordOptions="None" Password="" Verbose="True" />
67
+ </Properties>
68
+ </MonoDevelop>
69
+ <VisualStudio>
70
+ <FlavorProperties Guid="{349c5851-65df-11da-9384-00065b846f21}">
71
+ <WebProjectProperties>
72
+ <UseIIS>True</UseIIS>
73
+ <AutoAssignPort>True</AutoAssignPort>
74
+ <DevelopmentServerPort>48213</DevelopmentServerPort>
75
+ <DevelopmentServerVPath>/</DevelopmentServerVPath>
76
+ <IISUrl>http://localhost:48213/</IISUrl>
77
+ <NTLMAuthentication>False</NTLMAuthentication>
78
+ <UseCustomServer>False</UseCustomServer>
79
+ <CustomServerUrl>
80
+ </CustomServerUrl>
81
+ <SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
82
+ </WebProjectProperties>
83
+ </FlavorProperties>
84
+ <FlavorProperties Guid="{349c5851-65df-11da-9384-00065b846f21}" User="">
85
+ <WebProjectProperties>
86
+ <StartPageUrl>
87
+ </StartPageUrl>
88
+ <StartAction>CurrentPage</StartAction>
89
+ <AspNetDebugging>True</AspNetDebugging>
90
+ <SilverlightDebugging>False</SilverlightDebugging>
91
+ <NativeDebugging>False</NativeDebugging>
92
+ <SQLDebugging>False</SQLDebugging>
93
+ <ExternalProgram>
94
+ </ExternalProgram>
95
+ <StartExternalURL>
96
+ </StartExternalURL>
97
+ <StartCmdLineArguments>
98
+ </StartCmdLineArguments>
99
+ <StartWorkingDirectory>
100
+ </StartWorkingDirectory>
101
+ <EnableENC>False</EnableENC>
102
+ <AlwaysStartWebServerOnDebug>True</AlwaysStartWebServerOnDebug>
103
+ </WebProjectProperties>
104
+ </FlavorProperties>
105
+ </VisualStudio>
106
+ </ProjectExtensions>
107
+ <Target Name="BeforeBuild">
108
+ <MSBuild.ExtensionPack.FileSystem.File TaskAction="Replace" RegexPattern="&lt;dependentAssembly&gt;([\s]+.)&lt;assemblyIdentity name=&quot;FSharp\.Core&quot; publicKeyToken=&quot;b03f5f7f11d50a3a&quot; culture=&quot;neutral&quot; \/&gt;([\s\S]+?)&lt;\/dependentAssembly&gt;" RegexOptionList="IgnoreCase|Singleline" Replacement="&lt;dependentAssembly&gt;&#xD;&#xA; &lt;assemblyIdentity name=&quot;FSharp.Core&quot; publicKeyToken=&quot;b03f5f7f11d50a3a&quot; culture=&quot;neutral&quot; /&gt;&#xD;&#xA; &lt;bindingRedirect oldVersion=&quot;0.0.0.0-$(TargetFSharpCoreVersion)&quot; newVersion=&quot;$(TargetFSharpCoreVersion)&quot;/&gt;&#xD;&#xA; &lt;/dependentAssembly&gt;" Files="web.config" />
109
+ </Target>
110
+ <ItemGroup>
111
+ <Compile Include="AssemblyInfo.fs" />
112
+ <Content Include="Content\Site.css" />
113
+ <None Include="Content\bootstrap-theme.min.css" />
114
+ <None Include="Content\bootstrap-theme.css" />
115
+ <None Include="Content\bootstrap.min.css" />
116
+ <None Include="Content\bootstrap.css" />
117
+ <Content Include="Scripts\modernizr-2.6.2.js" />
118
+ <Content Include="Scripts\bootstrap.min.js" />
119
+ <Content Include="Scripts\bootstrap.js" />
120
+ <None Include="Scripts\jquery-2.0.3.min.map" />
121
+ <Content Include="Scripts\jquery-2.0.3.min.js" />
122
+ <Content Include="Scripts\jquery-2.0.3.js" />
123
+ <Content Include="Scripts\jquery-2.0.3.intellisense.js" />
124
+ <Content Include="Scripts\respond.min.js" />
125
+ <Content Include="Scripts\respond.js" />
126
+ <None Include="fonts\glyphicons-halflings-regular.woff" />
127
+ <None Include="fonts\glyphicons-halflings-regular.ttf" />
128
+ <None Include="fonts\glyphicons-halflings-regular.svg" />
129
+ <None Include="fonts\glyphicons-halflings-regular.eot" />
130
+ <Compile Include="Controllers\HomeController.fs" />
131
+ <Compile Include="Controllers\ValuesController.fs" />
132
+ <Content Include="Views\Web.config" />
133
+ <Content Include="Views\Home\Index.cshtml" />
134
+ <Content Include="Views\Shared\_Layout.cshtml" />
135
+ <Content Include="Views\Shared\Error.cshtml" />
136
+ <Content Include="Views\_ViewStart.cshtml" />
137
+ <Content Include="Web.config" />
138
+ <Content Include="Global.asax" />
139
+ <Compile Include="Global.asax.fs">
140
+ <DependentUpon>Global.asax</DependentUpon>
141
+ </Compile>
142
+ <None Include="packages.config" />
143
+ <Content Include="readme.txt" />
144
+ <None Include="local.pubxml" />
145
+ </ItemGroup>
146
+ <ItemGroup>
147
+ <Reference Include="Antlr3.Runtime">
148
+ <HintPath>..\packages\Antlr.3.4.1.9004\lib\Antlr3.Runtime.dll</HintPath>
149
+ <Private>True</Private>
150
+ </Reference>
151
+ <Reference Include="Microsoft.Web.Infrastructure">
152
+ <HintPath>$(SolutionDir)\packages\Microsoft.Web.Infrastructure.1.0.0.0\lib\net40\Microsoft.Web.Infrastructure.dll</HintPath>
153
+ <Private>True</Private>
154
+ </Reference>
155
+ <Reference Include="Newtonsoft.Json">
156
+ <HintPath>$(SolutionDir)\packages\Newtonsoft.Json.4.5.11\lib\net40\Newtonsoft.Json.dll</HintPath>
157
+ <Private>True</Private>
158
+ </Reference>
159
+ <Reference Include="System" />
160
+ <Reference Include="System.Net.Http" />
161
+ <Reference Include="System.Net.Http.Formatting">
162
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebApi.Client.5.0.0\lib\net45\System.Net.Http.Formatting.dll</HintPath>
163
+ <Private>True</Private>
164
+ </Reference>
165
+ <Reference Include="System.Web" />
166
+ <Reference Include="System.Web.ApplicationServices.dll" />
167
+ <Reference Include="System.Web.Helpers">
168
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebPages.3.0.0\lib\net45\System.Web.Helpers.dll</HintPath>
169
+ <Private>True</Private>
170
+ </Reference>
171
+ <Reference Include="System.Web.Http">
172
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebApi.Core.5.0.0\lib\net45\System.Web.Http.dll</HintPath>
173
+ <Private>True</Private>
174
+ </Reference>
175
+ <Reference Include="System.Web.Http.WebHost">
176
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebApi.WebHost.5.0.0\lib\net45\System.Web.Http.WebHost.dll</HintPath>
177
+ <Private>True</Private>
178
+ </Reference>
179
+ <Reference Include="System.Web.Mvc">
180
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.Mvc.5.0.0\lib\net45\System.Web.Mvc.dll</HintPath>
181
+ <Private>True</Private>
182
+ </Reference>
183
+ <Reference Include="System.Web.Optimization">
184
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.Web.Optimization.1.1.2\lib\net40\System.Web.Optimization.dll</HintPath>
185
+ <Private>True</Private>
186
+ </Reference>
187
+ <Reference Include="System.Web.Razor">
188
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.Razor.3.0.0\lib\net45\System.Web.Razor.dll</HintPath>
189
+ <Private>True</Private>
190
+ </Reference>
191
+ <Reference Include="System.Web.Services" />
192
+ <Reference Include="System.Web.WebPages">
193
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebPages.3.0.0\lib\net45\System.Web.WebPages.dll</HintPath>
194
+ <Private>True</Private>
195
+ </Reference>
196
+ <Reference Include="System.Web.WebPages.Deployment">
197
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebPages.3.0.0\lib\net45\System.Web.WebPages.Deployment.dll</HintPath>
198
+ <Private>True</Private>
199
+ </Reference>
200
+ <Reference Include="System.Web.WebPages.Razor">
201
+ <HintPath>$(SolutionDir)\packages\Microsoft.AspNet.WebPages.3.0.0\lib\net45\System.Web.WebPages.Razor.dll</HintPath>
202
+ <Private>True</Private>
203
+ </Reference>
204
+ <Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
205
+ <Private>True</Private>
206
+ </Reference>
207
+ <Reference Include="System.Xml" />
208
+ <Reference Include="System.Web.Routing" />
209
+ <Reference Include="System.Web.Abstractions" />
210
+ <Reference Include="System.ComponentModel.DataAnnotations" />
211
+ <Reference Include="System.Xml.Linq.dll" />
212
+ <Reference Include="WebGrease">
213
+ <HintPath>..\packages\WebGrease.1.5.2\lib\WebGrease.dll</HintPath>
214
+ <Private>True</Private>
215
+ </Reference>
216
+ </ItemGroup>
217
+ </Project>
@@ -0,0 +1 @@
1
+ <%@ Application Inherits="FSharpWeb.Global" %>
@@ -0,0 +1,71 @@
1
+ namespace FSharpWeb
2
+
3
+ open System
4
+ open System.Net.Http
5
+ open System.Web
6
+ open System.Web.Http
7
+ open System.Web.Mvc
8
+ open System.Web.Routing
9
+ open System.Web.Optimization
10
+
11
+ type BundleConfig() =
12
+ static member RegisterBundles (bundles:BundleCollection) =
13
+ bundles.Add(ScriptBundle("~/bundles/jquery").Include([|"~/Scripts/jquery-{version}.js"|]))
14
+
15
+ // Use the development version of Modernizr to develop with and learn from. Then, when you're
16
+ // ready for production, use the build tool at http://modernizr.com to pick only the tests you need.
17
+ bundles.Add(ScriptBundle("~/bundles/modernizr").Include([|"~/Scripts/modernizr-*"|]))
18
+
19
+ bundles.Add(ScriptBundle("~/bundles/bootstrap").Include(
20
+ "~/Scripts/bootstrap.js",
21
+ "~/Scripts/respond.js"))
22
+
23
+ bundles.Add(StyleBundle("~/Content/css").Include(
24
+ "~/Content/bootstrap.css",
25
+ "~/Content/site.css"))
26
+
27
+ /// Route for ASP.NET MVC applications
28
+ type Route = {
29
+ controller : string
30
+ action : string
31
+ id : UrlParameter }
32
+
33
+ type HttpRoute = {
34
+ controller : string
35
+ id : RouteParameter }
36
+
37
+ type Global() =
38
+ inherit System.Web.HttpApplication()
39
+
40
+ static member RegisterWebApi(config: HttpConfiguration) =
41
+ // Configure routing
42
+ config.MapHttpAttributeRoutes()
43
+ config.Routes.MapHttpRoute(
44
+ "DefaultApi", // Route name
45
+ "api/{controller}/{id}", // URL with parameters
46
+ { controller = "{controller}"; id = RouteParameter.Optional } // Parameter defaults
47
+ ) |> ignore
48
+
49
+ // Configure serialization
50
+ config.Formatters.XmlFormatter.UseXmlSerializer <- true
51
+ config.Formatters.JsonFormatter.SerializerSettings.ContractResolver <- Newtonsoft.Json.Serialization.CamelCasePropertyNamesContractResolver()
52
+
53
+ // Additional Web API settings
54
+
55
+ static member RegisterFilters(filters: GlobalFilterCollection) =
56
+ filters.Add(new HandleErrorAttribute())
57
+
58
+ static member RegisterRoutes(routes:RouteCollection) =
59
+ routes.IgnoreRoute("{resource}.axd/{*pathInfo}")
60
+ routes.MapRoute(
61
+ "Default", // Route name
62
+ "{controller}/{action}/{id}", // URL with parameters
63
+ { controller = "Home"; action = "Index"; id = UrlParameter.Optional } // Parameter defaults
64
+ ) |> ignore
65
+
66
+ member x.Application_Start() =
67
+ AreaRegistration.RegisterAllAreas()
68
+ GlobalConfiguration.Configure(Action<_> Global.RegisterWebApi)
69
+ Global.RegisterFilters(GlobalFilters.Filters)
70
+ Global.RegisterRoutes(RouteTable.Routes)
71
+ BundleConfig.RegisterBundles BundleTable.Bundles
@@ -0,0 +1,10 @@
1
+ <div class="jumbotron">
2
+ <h1>F# + ASP.NET</h1>
3
+ <p class="lead">Pure F# ASP.NET web apps are a combination of several excellent technologies that allow you to build complex web applications in less time. To make your experience
4
+ even more appealing, we recommend following the instructions on
5
+ <a href="http://bloggemdano.blogspot.com/2013/11/adding-new-items-to-pure-f-aspnet.html">this blog post</a> and
6
+ installing the <a href="http://visualstudiogallery.msdn.microsoft.com/f1dae7fe-1ecc-4f1b-86b5-32a2970d012a?SRC=Home">F# Web Item Templates</a>.
7
+ </p>
8
+ <p>To learn more about ASP.NET MVC or Web API visit the <a href="http://go.microsoft.com/fwlink/?LinkId=301870">ASP.NET site</a>.</p>
9
+ <p>To learn more about web programming in F# visit <a href="http://fsharp.org/webstacks/">fsharp.org</a></p>
10
+ </div>
@@ -0,0 +1,5 @@
1
+ @model System.Web.Mvc.HandleErrorInfo
2
+
3
+ <div>
4
+ <h2>An error occurred while processing your request.</h2>
5
+ </div>
@@ -0,0 +1,40 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <meta name="viewport" content="width=device-width" />
6
+ <title>@ViewBag.Title</title>
7
+ @Styles.Render("~/Content/css")
8
+ @Scripts.Render("~/bundles/modernizr")
9
+ </head>
10
+ <body>
11
+ <div class="navbar navbar-inverse navbar-fixed-top">
12
+ <div class="container">
13
+ <div class="navbar-header">
14
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
15
+ <span class="icon-bar"></span>
16
+ <span class="icon-bar"></span>
17
+ <span class="icon-bar"></span>
18
+ </button>
19
+ @Html.ActionLink("Application name", "Index", "Home", null, new { @class = "navbar-brand" })
20
+ </div>
21
+ <div class="navbar-collapse collapse">
22
+ <ul class="nav navbar-nav">
23
+ <li>@Html.ActionLink("Home", "Index", "Home", new { area = "" }, null)</li>
24
+ </ul>
25
+ </div>
26
+ </div>
27
+ </div>
28
+ <div class="container body-content">
29
+ @RenderBody()
30
+ <hr />
31
+ <footer>
32
+ <p>&copy; @DateTime.Now.Year - My ASP.NET Application</p>
33
+ </footer>
34
+ </div>
35
+
36
+ @Scripts.Render("~/bundles/jquery")
37
+ @Scripts.Render("~/bundles/bootstrap")
38
+ @RenderSection("scripts", required: false)
39
+ </body>
40
+ </html>