-
Notifications
You must be signed in to change notification settings - Fork 105
Description
When *.tt templates are placed in project subfolders T4.BuildTools tries to reproduce this folder structure in obj dir, however it doesn't create folder structure prior to write generated file. So it fails with following error.
Internal error: System.IO.DirectoryNotFoundException: Could not find a part of the path '...'. at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) at System.IO.StreamWriter.CreateFile(String path, Boolean append, Boolean checkHost) at System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize, Boolean checkHost) at System.IO.File.InternalWriteAllText(String path, String contents, Encoding encoding, Boolean checkHost) at System.IO.File.WriteAllText(String path, String contents, Encoding encoding) at Mono.TextTemplating.Build.TextTransformProcessor.WriteOutput(MSBuildTemplateGenerator generator, String outputFile, String outputContent, Encoding encoding) in /_/Mono.TextTemplating.Build/TextTransformProcessor.cs:line 184
I guess that simple directory existence/creation check should be added prior to write output.