bennor / autot4 Goto Github PK
View Code? Open in Web Editor NEWA zero-configuration extension for Visual Studio 2012+ which automatically runs your T4 templates at build time.
License: MIT License
A zero-configuration extension for Visual Studio 2012+ which automatically runs your T4 templates at build time.
License: MIT License
Have all the bugs been worked out? I've noticed lately my VS crashing lately when I click on a TT file.. Not sure if AutoT4 is the cause or not?
In code generation scenarios files are copied in to project directories, including *.tt files. Upon loading a solution, (at least in VS2017) new files added into a project folder are added in to the project file in Visual Studio. However, those files with a .tt extension do not have the Customer Tool property set.
It would be extremely useful to have this property set on all .tt files where it is blank.
Thanks!
Hi,
I installed this, and I have a EF edmx file in my solution with POCO generators.
However, when I build my solution, my generators are not triggered, I have mo manually open EF model and save it for generators to generate the POCO classes
Do I miss anything on setting this up?
Thanks
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.
When you have another project that is scanned by a template and that project contains modified source code, it would be nice to set the template has dependent of the other project build.
It would be similar to AutoRunCustomTool but for dependent projects of a template execution.
All templates could have a list of dependent projects.
This will ensure that unchanged built projects templates are always executed.
PS : Everything will be simpler in code, the explanation is for what will happen only.
When I try to install the extension from VS gallery or inside VS I always get the same error:
"The extension 'AutoT4' requires a version of the .NET Framework that is not installed"
I have .NET4.5 and ._NET4.5.1
Which version do I need?
I manage an internal framework which is currently has multiple projects. The version for the projects come from a single solution item called CommonAssemblyInfo.cs, which has been added as a link to each project.
I would like to add a build number to the version by using a .tt file in the same way. It would be a solution item which is added as a link in each project. I'm using AutoT4 to generate the .cs file from the .tt file at build time.
It seems to be working just fine except when I do a build I get an pop-up error "This document is opened by another project." I would guess that AutoT4 is trying to execute the template in each project that is using it, and then having a collision.
Can you tell me if that is the case and if there's anyway around it?
Using VS2015
I use a local file (EntityList.txt) in my solution which contains a list of entities. When I change this file I want my templates to run so they generate the appropriate code if I change this file content.
Perhaps we could have an AutoT4Settings.json file alongside the solution that could control AutoT4 behaviours such as this. We could have solution dependant behaviours then as well as version control applied.
Thanks!
Love this extension... thank you! I was curious if you could possibly add an extension property on the files property list (call it ExecuteOnBuild) that allows you to turn on/off template execution on build on a file-by-file basis.
Will you be making this available for Visual Studio 2015 anytime soon?
Please check.
Currently it seems only available as Visual Studio Extension
Note: I am on VS2015
At least one person wants this, so I might as well make it happen.
When an individual project changes, this compiles the tt files reliably. However, if I right-click "rebuild solution" tt files on projects with no changes are not rebuilt. Is this by design? I feel like forcing a rebuild should cause the tt files to be rebuilt too.
JetBrains introduced ReSharper Build around 10.2015 which is a replacement for the classic MsBuild procedure. (https://blog.jetbrains.com/dotnet/2015/10/15/introducing-resharper-build/)
Would it be possible to support their build-hook?
As described here on Stack Overflow:
I migrated a project.json/.xproj project to the newer CS2017 .csproj format.
The project contains a T4 (.tt) template file.
It doesn't regenerate its output on save or build. The output .cs file isn't nested below the .tt file either.
Is there something I have to do to get this working?
I installed AutoT4 1.2.1 and restarted VS, but it doesn't seem to update the output .cs file. Does this extension work with the newer .csproj project format?
Active project in solution dependencies should be scanned for templates.
Please add Visual Studio 2017 support
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.