Skip to content

Commit

Permalink
Merge pull request #154 from endjin/main
Browse files Browse the repository at this point in the history
Exposes the generator's UseRelativeLinePragmas option in the CLI tool.
  • Loading branch information
mhutch committed Oct 2, 2023
2 parents 2dd0b83 + f0950ef commit df8fda0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions dotnet-t4/TextTransform.cs
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,11 @@ static int MainInternal (string [] args)
"Preprocess the template into class {<name>} for use as a runtime template. The class name may include a namespace.",
(s) => preprocessClassName = s
},
{
"l|useRelativeLinePragmas",
"Use relative paths in line pragmas.",
s => generator.UseRelativeLinePragmas = true
},
{
"p==|parameter==",
"Set session parameter {0:<name>} to {1:<value>}. " +
Expand Down
1 change: 1 addition & 0 deletions dotnet-t4/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ Option | Description
`-I=<directory>` | Add a `<directory>` to be searched when resolving included files
`-P=<directory>` | Add a `<directory>` to be searched when resolving assemblies.
`-c`<br/>`--class=<name>` | Preprocess the template into class `<name>` for use as a runtime template. The class name may include a namespace.
`-l`<br/>`--useRelativeLinePragmas` | Use relative paths in line pragmas.
`-p`, `--parameter=<name>=<value>` | Set session parameter `<name>` to `<value>`. The value is accessed from the template's `Session` dictionary, or from a property declared with a parameter directive: `<#@ parameter name='<name>' type='<type>' #>.` <br/> If the `<name>` matches a parameter with a non-string type, the `<value>` will be converted to that type.
`--debug` | Generate debug symbols and keep temporary files.
`-v` <br/> `--verbose` | Output additional diagnostic information to stdout.
Expand Down

0 comments on commit df8fda0

Please sign in to comment.