Repository navigation
Update template --allow-scripts help text with explicit trust warning and propagate localization source updates - #54393
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the dotnet new template --allow-scripts option description to include an explicit security warning about arbitrary code execution via MSBuild, and propagates the updated English source string across localization files so translations are flagged for review.
Changes:
- Expanded
TemplateCommand_Option_AllowScriptshelp text inSymbolStrings.resxwith an explicit trust warning. - Regenerated
SymbolStrings.*.xlfso the updated<source>is reflected across locales. - Marked existing translations for the updated key as
needs-review-translation.
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/SymbolStrings.resx | Updates the English help text for --allow-scripts with an explicit security warning. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.cs.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.de.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.es.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.fr.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.it.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.ja.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.ko.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.pl.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.pt-BR.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.ru.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.tr.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.zh-Hans.xlf | Updates localization source string and marks translation as needing review. |
| src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/SymbolStrings.zh-Hant.xlf | Updates localization source string and marks translation as needing review. |
|
@copilot Update DotnetNewHelpTests.CanShowAllowScriptsOption.verified.txt for the new string to fix the tests. |
Updated |
This reverts commit fd3d70a. Co-authored-by: marcpopMSFT <[email protected]>
Co-authored-by: marcpopMSFT <[email protected]>
Co-authored-by: marcpopMSFT <[email protected]>
298323a to
1e0e799
Compare
| --no-update-check Disables checking for the template package updates when instantiating a template. [default: False] | ||
| --project <project> The project that should be used for context evaluation. | ||
| --allow-scripts <No|Prompt|Yes> Specifies if post action scripts should run. [default: Prompt] | ||
| --allow-scripts <No|Prompt|Yes> Specifies if post action scripts should run. Templates can run arbitrary code through MSBuild whether or not this option is enabled; only use templates from trusted sources. [default: Prompt] |
There was a problem hiding this comment.
Nit - it might be more precise to use regardless of this setting instead of whether or not this option is enabled as this isn't a boolean-type option.
This updates the
TemplateCommand_Option_AllowScriptsmessage inSymbolStrings.resxto include a clear security warning about arbitrary code execution via MSBuild. The localization source strings are regenerated so translation files track the new English source and require translation review.Resource text update
--allow-scriptsdescription in:src/Cli/Microsoft.TemplateEngine.Cli/Commands/SymbolStrings.resxLocalization propagation
SymbolStrings.*.xlfunder:src/Cli/Microsoft.TemplateEngine.Cli/Commands/xlf/<source>forTemplateCommand_Option_AllowScriptsacross locales.needs-review-translationfor this key.