<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.3.3" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: T4 Tutorial: Reusing code generators on multiple projects</title>
	<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/</link>
	<description>Interfaces are like alcohol - they are a lot of fun when used in moderation.</description>
	<pubDate>Sat, 04 Feb 2012 05:50:52 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.3</generator>
		<item>
		<title>By: Oleg Sych</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-3477</link>
		<dc:creator>Oleg Sych</dc:creator>
		<pubDate>Tue, 13 Dec 2011 22:24:49 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-3477</guid>
		<description>Arnon, to answer your questions,

1. My goal is to be able to pull a labeled version from the source control repository and recreate the build successfully. If I have to re-generate the code, I want both model and code generation templates in repository. If I can’t accomplish that – let’s say that my model is a database that I cannot store in the repository, my next best option is to store the generated code itself under source control.

2. Yes, you can compile the code generation templates and redistribute them in binary form. In that case, you have to treat it as an external binary reference in every project that uses them. Unless you store these binaries under source control, this approach actually increases the risk of you not being able to reproduce a build later. I suspect your preference in choosing the approach will be based on whether you need to support prior versions of whatever you are building or not.</description>
		<content:encoded><![CDATA[<p>Arnon, to answer your questions,</p>
<p>1. My goal is to be able to pull a labeled version from the source control repository and recreate the build successfully. If I have to re-generate the code, I want both model and code generation templates in repository. If I can’t accomplish that – let’s say that my model is a database that I cannot store in the repository, my next best option is to store the generated code itself under source control.</p>
<p>2. Yes, you can compile the code generation templates and redistribute them in binary form. In that case, you have to treat it as an external binary reference in every project that uses them. Unless you store these binaries under source control, this approach actually increases the risk of you not being able to reproduce a build later. I suspect your preference in choosing the approach will be based on whether you need to support prior versions of whatever you are building or not.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Arnon Axelrod</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-3476</link>
		<dc:creator>Arnon Axelrod</dc:creator>
		<pubDate>Sun, 11 Dec 2011 12:51:17 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-3476</guid>
		<description>Great articles Oleg!
I have 2 questions regarding this post:
1. It's very clear to me that I need to store the code generation files in the source control, but I don't understand why I need to keep the *generated code* there too. I would think that the code generator should be run in a pre-build step.
2. Isn't it possible to compile all the reusable stuff (everything except for the script) into a dll, and thus avoid the path issue? Also, it will be easier to deploy and re-use between projects and avoid different teams from evloving the code in different directions (because the source code of the generators won't be copied between source repositories, only the binary).</description>
		<content:encoded><![CDATA[<p>Great articles Oleg!<br />
I have 2 questions regarding this post:<br />
1. It&#8217;s very clear to me that I need to store the code generation files in the source control, but I don&#8217;t understand why I need to keep the *generated code* there too. I would think that the code generator should be run in a pre-build step.<br />
2. Isn&#8217;t it possible to compile all the reusable stuff (everything except for the script) into a dll, and thus avoid the path issue? Also, it will be easier to deploy and re-use between projects and avoid different teams from evloving the code in different directions (because the source code of the generators won&#8217;t be copied between source repositories, only the binary).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Oleg Sych</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-2648</link>
		<dc:creator>Oleg Sych</dc:creator>
		<pubDate>Sun, 27 Dec 2009 21:24:36 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-2648</guid>
		<description>Thanks, Bill. This is a good point. I have updated the article.</description>
		<content:encoded><![CDATA[<p>Thanks, Bill. This is a good point. I have updated the article.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bill</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-2593</link>
		<dc:creator>Bill</dc:creator>
		<pubDate>Tue, 22 Dec 2009 13:32:52 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-2593</guid>
		<description>Thank you for the articles. They have been most useful.

If you are running a 64-bit OS, the key is [HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\9.0\TextTemplating\IncludeFolders\.tt]

It took me a little while to determine why your advice did not work.

Thanks again.</description>
		<content:encoded><![CDATA[<p>Thank you for the articles. They have been most useful.</p>
<p>If you are running a 64-bit OS, the key is [HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\9.0\TextTemplating\IncludeFolders\.tt]</p>
<p>It took me a little while to determine why your advice did not work.</p>
<p>Thanks again.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Oleg Sych</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-2411</link>
		<dc:creator>Oleg Sych</dc:creator>
		<pubDate>Thu, 05 Nov 2009 14:13:04 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-2411</guid>
		<description>Updated source code to be compatible with version 9.10 of the T4 Toolbox.</description>
		<content:encoded><![CDATA[<p>Updated source code to be compatible with version 9.10 of the T4 Toolbox.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Kamoski</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1926</link>
		<dc:creator>Mark Kamoski</dc:creator>
		<pubDate>Tue, 11 Aug 2009 20:24:01 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1926</guid>
		<description>BTW, in case anyone is interested, I followed Oleg's instructions above but I added the "reusable files" to a new custom class library project so I could "Add Existing Project" to my Solution and that works great. That "class libary" is just a placeholder to hold the reusable TT files and it makes adding them to a solution a bit easier, IMHO. There is no DLL created, probably because it has no classes in it. Anyway, that works for me-- but if anyone sees an issue, then please let me know. Thank you. -- Mark Kamoski</description>
		<content:encoded><![CDATA[<p>BTW, in case anyone is interested, I followed Oleg&#8217;s instructions above but I added the &#8220;reusable files&#8221; to a new custom class library project so I could &#8220;Add Existing Project&#8221; to my Solution and that works great. That &#8220;class libary&#8221; is just a placeholder to hold the reusable TT files and it makes adding them to a solution a bit easier, IMHO. There is no DLL created, probably because it has no classes in it. Anyway, that works for me&#8211; but if anyone sees an issue, then please let me know. Thank you. &#8212; Mark Kamoski</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Kamoski</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1925</link>
		<dc:creator>Mark Kamoski</dc:creator>
		<pubDate>Tue, 11 Aug 2009 20:20:05 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1925</guid>
		<description>Nice. Absolute patsh work like a charm. This stuff is great. Thanks so much for pointing it out, etc, Oleg. I now have a base class generator for tables with a CRUD implementation and a GetByUniqueKey option, along with a ViewBaseClass generator, and a Utility generator, and etc. Nice. I will try to find time to package it and upload it at http://www.codeplex.com/t4toolbox/ if I can make it "useful to others". Thank you. -- Mark Kamoski</description>
		<content:encoded><![CDATA[<p>Nice. Absolute patsh work like a charm. This stuff is great. Thanks so much for pointing it out, etc, Oleg. I now have a base class generator for tables with a CRUD implementation and a GetByUniqueKey option, along with a ViewBaseClass generator, and a Utility generator, and etc. Nice. I will try to find time to package it and upload it at <a href="http://www.codeplex.com/t4toolbox/" rel="nofollow">http://www.codeplex.com/t4toolbox/</a> if I can make it &#8220;useful to others&#8221;. Thank you. &#8212; Mark Kamoski</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Oleg Sych</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1924</link>
		<dc:creator>Oleg Sych</dc:creator>
		<pubDate>Tue, 11 Aug 2009 16:46:37 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1924</guid>
		<description>Yes, &lt;a href="http://www.olegsych.com/2008/02/t4-include-directive/" rel="nofollow"&gt;include directive&lt;/a&gt; supports absolute paths. I hope this limitation will be addressed in Visual Studio 2010.</description>
		<content:encoded><![CDATA[<p>Yes, <a href="http://www.olegsych.com/2008/02/t4-include-directive/" rel="nofollow">include directive</a> supports absolute paths. I hope this limitation will be addressed in Visual Studio 2010.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Kamoski</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1922</link>
		<dc:creator>Mark Kamoski</dc:creator>
		<pubDate>Tue, 11 Aug 2009 16:29:41 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-1922</guid>
		<description>I appreciate the workaround. This is a BIG problem in the core T4 implementation at the VS.NET level, IMHO-- they really need to fix that. To have to tell all devleopers on the development team to hack their Registry to do this is not nice and will likely meet with resitance. Can one use absolute paths in the include paths? I know this might sound silly; but, our dev machine build guarantees all our code is in "C:\Code" on every machine; so, if absolute paths work, then I might go that route. Thoughts?</description>
		<content:encoded><![CDATA[<p>I appreciate the workaround. This is a BIG problem in the core T4 implementation at the VS.NET level, IMHO&#8211; they really need to fix that. To have to tell all devleopers on the development team to hack their Registry to do this is not nice and will likely meet with resitance. Can one use absolute paths in the include paths? I know this might sound silly; but, our dev machine build guarantees all our code is in &#8220;C:\Code&#8221; on every machine; so, if absolute paths work, then I might go that route. Thoughts?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Designing Out Loud in the .NET Space : T4 Parameter Passing: Stuff Found on the Web</title>
		<link>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-636</link>
		<dc:creator>Designing Out Loud in the .NET Space : T4 Parameter Passing: Stuff Found on the Web</dc:creator>
		<pubDate>Thu, 23 Oct 2008 22:44:32 +0000</pubDate>
		<guid>http://www.olegsych.com/2008/10/t4-tutorial-reusing-code-generators-on-multiple-projects/#comment-636</guid>
		<description>[...] Sych on T4 Tutorial: Reusing code generators on multiple projects: and even more grist for the [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] Sych on T4 Tutorial: Reusing code generators on multiple projects: and even more grist for the [&#8230;]</p>
]]></content:encoded>
	</item>
</channel>
</rss>

