We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I hate the redundancy of specifying commands like this to preprocess templates:
t4 -c MyTemplate MyTemplate.tt
I'd love to see a new option that infers the class name from the input file so I can just specify something like this:
t4 --preprocess MyTemplate.tt
The text was updated successfully, but these errors were encountered:
Hmm, looks like you'd also need a way to specify the namespace.
Maybe this issue isn't really worth it in the end.
Sorry, something went wrong.
This seems reasonable to me - even if it's no more concise, eliminating redundancy helps reduce user error.
Maybe just t4 -n SomeNamespace SomeClassname.tt ?
t4 -n SomeNamespace SomeClassname.tt
@bricelam If you are add command in project config file (e.g. csproj), you may try the method of https://github.com/nogic1008/T4Sample.
<Exec WorkingDirectory="$(ProjectDir)" Command="dotnet t4 %(TextTemplate.Identity) -c $(RootNameSpace).%(TextTemplate.Filename) -o %(TextTemplate.Filename).Generated.cs" />
No branches or pull requests
I hate the redundancy of specifying commands like this to preprocess templates:
I'd love to see a new option that infers the class name from the input file so I can just specify something like this:
The text was updated successfully, but these errors were encountered: