<p dir="auto">We can no longer package Azure web roles containing TypeScript since upgrading to Visual Studio 2015 Update 1. One of my colleagues managed to restore the functionality by uninstalling the latest TypeScript and repairing TypeScript Tools for Visual Studio 1.5.3.0. For others (like me): no such luck.</p>
<p dir="auto"><strong>Blocking symptom:</strong></p>
<ul dir="auto">
<li>When packaging a web role for a web application containing TypeScript, there will be multiple errors: "The given path's format is not supported.", In the build output it is seen that the target path where msbuild tries to copy the output javascript file is incorrect. For example:</li>
</ul>
<p dir="auto"><code class="notranslate">2&gt;C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\Windows Azure Tools\2.7\Microsoft.WindowsAzure.targets(2787,5): error MSB3021: Unable to copy file "D:\Users\b.engelbrecht\Documents\Visual Studio 2015\Projects\TestTs\TestTs\Eform\config.js" to "D:\Users\b.engelbrecht\Documents\Visual Studio 2015\Projects\TestTs\TestTsCloud\obj\Release\TestTs\D:\Users\b.engelbrecht\Documents\Visual Studio 2015\Projects\TestTs\TestTs\Eform\config.js". The given path's format is not supported.</code></p>
<p dir="auto">Note that the target path looks like two paths concatenated, with the drive letter D:\ appearing twice in the path (which indeed is an illegal path format).</p>
<p dir="auto">I tried installing TypeScript 1.7.4.0 for Visual Studio 2015 Update 1 (release date December 17, 2015) in the hope that the bug would be fixed, but unfortunately that did not resolve the problem..</p>
<p dir="auto"><strong>Steps to reproduce, from scratch:</strong></p>
<ul dir="auto">
<li>Install Visual Studio 2015 RTM</li>
<li>Install Azure Tools 2.7</li>
<li>Install Visual Studio 2015 Update 1</li>
<li>Install TypeScript 1.7.4.0 for Visual Studio 2015 Update 1</li>
<li>Create a new solution with an empty MVC web application</li>
<li>Add a new directory to the web application and add a simple .ts file to that directory. Check that the application builds</li>
<li>Add an Azure Cloud Service project to the solution, associate the cloud service with the MVC web application</li>
<li>Try to package the cloud service. This fails with two errors as shown above (one for the .js output and one for the .js.map output file of the .ts file).</li>
</ul>
<p dir="auto"><strong>Steps to reproduce, using prepared sample solution:</strong></p>
<ul dir="auto">
<li>Download the sample solution <a href="http://support.decos.nl/Berend/TestTs-20151223.zip" rel="nofollow">http://support.decos.nl/Berend/TestTs-20151223.zip</a></li>
<li>Open solution in Visual Studio 2015 Update 1 with Azure tools 2.7 and latest TypeScript installed</li>
<li>Go to menu Tools &gt; NuGet Package Manager &gt; Manage NuGet Packages for Solution ...</li>
<li>The package manager shows a warning "Some NuGet packages are missing ...". Click the [Restore] button to the right of the warning (packages were not included in the sample zip to reduce download size).</li>
<li>Close package manager after restoring packages, try to build the web application TestTs. This should now proceed warning-free.</li>
<li>Right-click the web role project TestTsCloud, select "Package...". For me, this fails with two "The given path's format is not supported." errors.</li>
</ul>
<p dir="auto">I sincerely hope this can be resolved soon. In our team, developers having installed Visual Studio 2015 Update 1 can no longer create Azure packages for roles containing TypeScript. Since we heavily use Azure, the problem is severe.</p>
<h1 dir="auto">Summary</h1>
<p dir="auto">Installing TypeScript 1.7 tooling for Visual Studio causes different behaviour from 1.6 when publishing web applications, both from within Visual Studio (right click &gt; publish) and via msbuild.exe (<code class="notranslate">/p:DeployOnBuild=true</code>).</p>
<p dir="auto">This issue has only been observed using a file system publish.</p>
<h1 dir="auto">Symptoms</h1>
<p dir="auto">Generated JavaScript is no longer included in the packaged / published output.</p>
<h1 dir="auto">Observations</h1>
<p dir="auto">It appears there is a difference in the MSBuild <code class="notranslate">Content</code> ItemGroup's metadata. I believe that previously the generated JavaScript files were being included in the <code class="notranslate">Content</code> ItemGroup as paths relative to the <code class="notranslate">.csproj</code> file:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Scripts\App.js    "><pre class="notranslate"><code class="notranslate">Scripts\App.js    
</code></pre></div>
<p dir="auto">As of 1.7 it appears the generated JavaScript files are now being included in <code class="notranslate">Content</code> as absolute paths:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="C:\Projects\Solution\Web\Scripts\App.js"><pre class="notranslate"><code class="notranslate">C:\Projects\Solution\Web\Scripts\App.js
</code></pre></div>
<p dir="auto">Perhaps this is causing a problem for the web publishing mechanism?</p>