bennor / AutoT4

A zero-configuration extension for Visual Studio 2012+ which automatically runs your T4 templates at build time.
MIT License
11 stars 14 forks source link

How to specify which TT files to run. I.e. exclude TT files from being AutoTransformed #4

Closed VagyokC4 closed 9 years ago

VagyokC4 commented 9 years ago

This tool works (only too well). I've tried others that throw an error trying to transform my TT files.

However, I need to be able to specify which files should be Transformed so that this tool doesn't blanket transform all my TT files upon build.

One suggestion would be to check the 'Build Action' on the TT file, and only transform if it is set to 'None' this way I could selectively set the TT files I don't want transformed to 'Content' and have them skipped.

VagyokC4 commented 9 years ago

Created a Pull Request for this functionality: https://github.com/bennor/AutoT4/pull/5

bennor commented 9 years ago

This is a creative approach, but I feel like setting them to Content (meaning they'll be included in the build output) is a little bit hacky. I've nearly finished the other approach, so I will get that live by Saturday. (I will try for earlier if I get time.)

VagyokC4 commented 9 years ago

+1

Also maybe add support for VS 2015 while you're at it :)

bennor commented 9 years ago

Will do. (I may have already done that too.)