Rush StackShopBlogEvents
Skip to main content

Home > @rushstack/ts-command-line > CommandLineParameterProvider > defineStringParameter

CommandLineParameterProvider.defineStringParameter() method

Defines a command-line parameter whose argument is a single text string.

Signature:

defineStringParameter(definition: ICommandLineStringDefinition): CommandLineStringParameter;

Parameters

ParameterTypeDescription
definitionICommandLineStringDefinition

Returns:

CommandLineStringParameter

Remarks

Example usage of a string parameter:

example-tool --message "Hello, world!"