I'll try to be as specific as possible.
We work with TFS and we use typescript for client-side scripts.
When we develop locally we can do everything perfectly normal but the problem es whith the published websites from TFS.
The problem is that when we want to do a deploy, or if we want to automatize it, we need to do a workaround because under _PublishedWebsites typescript seems to not pile anything, and the scripts folder only contains the .ts files.
For now, the workaround is to go to the build folder and copy from there the .js files. This workaround works for now but I think the ideal scenario would be to have the .js files generated under the _PublishedWebsites folder.
We've tried different options but we couldn't find a solution yet, also the information found around is not very huge.
Any help would be appreciated.
Thanks.
EDIT: we are using VS 2013 and latest TFS and Typescript version. The ts files are added in a MVC project.
I'll try to be as specific as possible.
We work with TFS and we use typescript for client-side scripts.
When we develop locally we can do everything perfectly normal but the problem es whith the published websites from TFS.
The problem is that when we want to do a deploy, or if we want to automatize it, we need to do a workaround because under _PublishedWebsites typescript seems to not pile anything, and the scripts folder only contains the .ts files.
For now, the workaround is to go to the build folder and copy from there the .js files. This workaround works for now but I think the ideal scenario would be to have the .js files generated under the _PublishedWebsites folder.
We've tried different options but we couldn't find a solution yet, also the information found around is not very huge.
Any help would be appreciated.
Thanks.
EDIT: we are using VS 2013 and latest TFS and Typescript version. The ts files are added in a MVC project.
Share Improve this question edited Feb 12, 2014 at 16:08 Wallack asked Feb 12, 2014 at 9:51 WallackWallack 7924 silver badges15 bronze badges 1- You haven't mentioned what you're using. Which version of TFS & VisualStudio? The problem is probably that you're not using TypeScript project. So, is the problem same if you're new developer and & get latest? I can think of creating new utilty that piles recursively those files, which is invoked by visual studio post-build event in project settings. tsc might have some options too – Erti-Chris Eelmaa Commented Feb 12, 2014 at 15:35
3 Answers
Reset to default 4I had the same problem and the following worked for me:
- Within Visual Studio right click on your project and unload it.
- Right click on the project again and edit the csproj.
- Make sure that the Typescript import es directly after Microsoft.CSharp.targets.
Example:
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\TypeScript\Microsoft.TypeScript.targets" />
Fixed automatically with the latest update!
How are you trying to deploy or automate it?
If you are just doing a web deploy, or a similar deployment through visual studio, then keeping the javascript files as part of the solution should solve this.
If you are doing continuous integration with TFS, or doing another automated build, you need to install TypeScript on the build server and run the piler on bulid.
Another option(which i have done when i did not have access to the build server) is to copy the TypeScript piler into the TFS project and check it in and point the project to the new location.
Some more possibly helpful information is available here: http://manfredlange.blogspot.co.nz/2014/01/aspnet-mvc-typescript-azure-website-and.html
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745106233a4611571.html
评论列表(0条)