Reputation: 2789
When I execute my Fake build script I run into a problem where the parenthesis in my project file seem to be converted to %28 and %29 respectively. This results in a failed build.
Here is my FAKE script below:
// include Fake lib
#I @"../tools/FAKE/tools/"
#r @"FakeLib.dll"
open Fake
let buildDir = "./.build"
let dotNet40ProjectsIncludeStr = "**/*(NET40).*proj"
let dotNet40Projects =
!! dotNet40ProjectsIncludeStr
let dotNet45Projects =
!! "**/*.*proj"
-- dotNet40ProjectsIncludeStr
// Default target
Target "Default" (fun _ ->
trace "Executed Default target"
)
Target "Build NET45" (fun _ ->
dotNet45Projects |> Seq.iter (log << sprintf "%s%s" "Net45Projects:")
MSBuildRelease (buildDir @@ "net45") "Build" dotNet45Projects
|> Log "BuildNet45: "
)
Target "Build NET40" (fun _ ->
//let projects = dotNet40Projects |> Seq.map (sprintf "%s")
//projects |> Seq.iter (log << sprintf "%s%s" "Net40Projects:")
dotNet40Projects |> Seq.iter (log << sprintf "%s%s" "Net40Projects:")
MSBuildRelease (buildDir @@ "net40") "Build" dotNet40Projects
|> Log "BuildNet40: "
)
"Build NET40"
==> "Build NET45"
==> "Default"
// start build
RunTargetOrDefault "Default"
The output I get contains the following:
Starting Target: Build NET40 Net40Projects:C:\dev\work\My- Company\dev\MyProject\Data\MyProject\MyProject.Data(NET40).csproj
Net40Projects:C:\dev\work\My-Company\dev\MyProject\Data\MyProject.Data.Tests\MyProject.Data.Tests(NET40).cspr oj
Running build failed.
Error:
System.IO.FileNotFoundException: Could not find file 'C:\dev\work\MyCompany\dev\MyProject\Data\MyProject.Data\MyProject.Data%28NET40%29.csproj'.
Upvotes: 2
Views: 397
Reputation: 2814
I consider this as a bug. Please open an issue in fake's github issue tracker.
Upvotes: 3