自定义 T4 生成器生成的类看起来很乱

发布于 2024-12-22 15:58:39 字数 85 浏览 1 评论 0原文

运行生成器输出文件后,代码看起来确实很混乱。我知道我可能永远不会查看这些文件,但很高兴在开发生成器时看到生成的代码结构良好。

欢迎任何建议。

After running the generator output files with code look really disordered. I know I will probably never look into those files but it is nice to see generated code nicely structured while developing a generator.

Any suggestions are welcome.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

别忘他 2024-12-29 15:58:39

永远不要查看这些文件

只要代码有效,就 ,谁在乎呢。安息吧朋友,继续做更重要的事情:)

但是如果你真的想这样做,我建议在你的持续构建系统中添加一个代码重新格式化过程。请参阅如何强制代码样式格式化作为构建? 为例

never look into those files

as long as the code works, who cares. rest easy friend, move on to more important things :)

but if you REALLY want to do this, I'd suggest adding a code-reformatting process to your continuous build system. see How to force code style formatting as part of the build? for an example

锦上情书 2024-12-29 15:58:39

更改您的 t4 代码以使输出代码更整洁...或者不看。

Change your t4 code to make the output code neater... or don't look.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文