I use dotnet-t4 to perform Text transformation as part of built process i.e., BeforeBuild. In a solution where text transformation is performed before build in multiple projects with dotnet-t4, build failed with "Unable to create temp file as the file already exists".