Internet Explorer is no longer supported. Many things will still work, but your experience will be degraded and some things won't function. Please use a modern browser such as Edge, Chrome, or Firefox.

• $ApplicationDescription([appName]) - description of the current or specified application ##$ApplicationDescription

description of the current or specified application

#### Parameters:

Name Description
Name The name of the application to look for.
IncludeInactive When false, this function will return false if the specified application exists but is inactive; otherwise, it will return true for inactive applications as well. The default value is false.
• $ApplicationGroupName - name of the current application group ##$ApplicationGroupName

name of the current application group

#### Script usage:

$ApplicationGroupName •$ApplicationName - name of the current application

## $ApplicationName name of the current application #### Script usage: $ApplicationName
• @ApplicationsInGroup(groupName) - list of applications which belong to the specified application group

## @ApplicationsInGroup

list of applications which belong to the specified application group

#### Script usage:

@ApplicationsInGroup(groupName)

#### Parameters:

Name Description
groupName Application Group Name
• @ReleasesInApplication([ApplicationName], [Status]) - Gets a list of release numbers in an application, optionally filtered by status.

## @ReleasesInApplication

Gets a list of release numbers in an application, optionally filtered by status.

#### Script usage:

@ReleasesInApplication([ApplicationName], [Status])

#### Parameters:

Name Description
ApplicationName Application Name
Status active, deployed, cancelled, or any

• $ArtifactPath(ArtifactName, [buildNumber], [releaseNumber], [applicationName]) - gets the path within the internal disk store for the specified artifact ##$ArtifactPath

gets the path within the internal disk store for the specified artifact

#### Parameters:

Name Description
Page Must be "application", "release", or "build"
ApplicationName Application Name
ReleaseNumber Release Number
BuildNumber Build Number
• $BuildMasterUrl(Page, [ApplicationName], [ReleaseNumber], [BuildNumber]) - Gets the URL of the specified page. ##$BuildMasterUrl

Gets the URL of the specified page.

#### Parameters:

Name Description
releaseNum Release Number
furthestOrLatest Must be "furthest" or "latest"; the default is "latest".
appName Application Name
• @BuildsInRelease([ReleaseNumber], [ApplicationName], [Status], [PipelineStage]) - Gets a list of builds in a release, optionally filtered by status and pipeline stage.

## @BuildsInRelease

Gets a list of builds in a release, optionally filtered by status and pipeline stage.

#### Script usage:

@BuildsInRelease([ReleaseNumber], [ApplicationName], [Status], [PipelineStage])

#### Parameters:

Name Description
ReleaseNumber Release Number
ApplicationName Application Name
Status active, deployed, rejected, or any
PipelineStage Pipeline Stage
• BuildVariable(VariableName, [BuildNumber], [ReleaseNumber], [ApplicationName]) - Gets the value of a variable defined on a build.

## BuildVariable

Gets the value of a variable defined on a build.

#### Script usage:

BuildVariable(VariableName, [BuildNumber], [ReleaseNumber], [ApplicationName])

#### Parameters:

Name Description
VariableName Variable Name
BuildNumber Build Number
ReleaseNumber Release Number
ApplicationName Application Name

## Configuration Files

• @ConfigurationFileInstances(configurationFileName, [appName]) - list configuration file instances defined for an application

## @ConfigurationFileInstances

list configuration file instances defined for an application

#### Script usage:

@ConfigurationFileInstances(configurationFileName, [appName])

#### Parameters:

Name Description
configurationFileName The name of the configuration file.
appName The name of the application.
• @ConfigurationFiles([appName]) - list configuration files defined for an application

## @ConfigurationFiles

list configuration files defined for an application

#### Script usage:

@ConfigurationFiles([appName])

#### Parameters:

Name Description
appName The name of the application.
• $ConfigurationFileText(instance, [fileName], [releaseNum]) - text contents of the specified configuration file instance ##$ConfigurationFileText

text contents of the specified configuration file instance

#### Parameters:

Name Description
fileName The name of the configuration file, or defaults to single configuration file for the contextual deployable.
releaseNum A specific release number, or defaults to contextual release number.

• $ContainerDigest(repositoryName, [tag], [sourceName]) - Gets the digest of a Docker image. The digest is from the image associated with the current build. ##$ContainerDigest

Gets the digest of a Docker image. The digest is from the image associated with the current build.

#### Parameters:

Name Description
repositoryName Repository Name
sourceName Source Name

• $SecureCredentialProperty(credential, property) - the decrypted plain text value of a specified credentials property ##$SecureCredentialProperty

the decrypted plain text value of a specified credentials property

$SecureCredentialProperty(credential, property) #### Parameters: Name Description credential The name of the credential to read. property The name of the credential property to get. If the property is encrypted, the credential itself must be configured to allow the value to be extracted, otherwise the function call will fail at run time. #### Example: # HDarsUser is a Username & Password Credentials with 'Allow encrypted properties...' checked set$username = $SecureCredentialProperty(HDarsUser, Username); set$password = $SecureCredentialProperty(HDarsUser, Password); Log-Debug Executing sometool.exe -user$username -pass *****;
Exec sometool.exe -user $username -pass$password;

• $SecureResourceProperty(resource, property) - the value of a specified secure resource property ##$SecureResourceProperty

the value of a specified secure resource property



## Databases

• @DatabaseConnectionsInEnvironment([environmentName]) - list of database connections for the current application which belong to the specified environment

## @DatabaseConnectionsInEnvironment

list of database connections for the current application which belong to the specified environment

#### Script usage:

@DatabaseConnectionsInEnvironment([environmentName])

#### Parameters:

Name Description
environmentName Environment Name

## Deployables

• @DependentApplications([appName]) - list of applications which import at least one deployable from the specified application

## @DependentApplications

list of applications which import at least one deployable from the specified application

#### Script usage:

@DependentApplications([appName])

#### Parameters:

Name Description
appName The name of the application to return dependents for. If not specified, the application in the current context is used.
• @DependentReleases(appName) - list of active or deployed releases from the specified application with at least one deployable imported from the current release of the current application

## @DependentReleases

list of active or deployed releases from the specified application with at least one deployable imported from the current release of the current application

#### Script usage:

@DependentReleases(appName)

#### Parameters:

Name Description
appName The name of the application that references the current application.
• $DeployableName([depName], [releaseNum]) - name of the current deployable in context ##$DeployableName

name of the current deployable in context

#### Parameters:

Name Description
depName The application-qualified name of the deployable (e.g. AppName::DeployableName); when no application name is specified, the current application in context will be used.
releaseNum Release Number
• $ReferencedPackageNumber([depName], [releaseNum], [furthestOrLatest]) - build number referenced by the current or specified deployable ##$ReferencedPackageNumber

build number referenced by the current or specified deployable

#### Parameters:

Name Description
depName The application-qualified name of the deployable (e.g. AppName::DeployableName); when no application name is specified, the current application in context will be used.
releaseNum Release Number
• $ReferencedReleaseNumber([depName], [releaseNum]) - release number of the current deployable in context ##$ReferencedReleaseNumber

release number of the current deployable in context

#### Parameters:

Name Description
ContainerSource Container Registry Secured Resource Name
RepositoryName Container Repository name
Tag eg. $ReleaseNumber-ci.$BuildNumber

• $ExecutionId - Returns the current execution ID. ##$ExecutionId

Returns the current execution ID.

#### Script usage:

$ExecutionId •$ExecutionState - Returns the current state of the execution (normal, warning, or error).

• $ExecutionUser - user name that initiated the current execution ##$ExecutionUser

user name that initiated the current execution

• $IsRollback - true if a build from an earlier release is redeployed to a stage ##$IsRollback

true if a build from an earlier release is redeployed to a stage

#### Script usage:

$IsRollback •$IsVariableDefined(VariableName, [VariableType]) - Returns true if the specified variable name is available in the current context; otherwise returns false.

#### Parameters:

Name Description
VariableName The name of the variable.
VariableType Must be one of: any, scalar, vector, or map; when none is specified, "any" is used.
• $WorkingDirectory - Returns the current working directory. ##$WorkingDirectory

Returns the current working directory.

$WorkingDirectory ## Files •$DirectoryExists(name) - Returns "true" if the specified directory exists on the current server.

#### Parameters:

Name Description
name The path of the directory.
• $FileContents(name, [maxLength]) - Returns the contents of a file on the current server. ##$FileContents

Returns the contents of a file on the current server.

#### Parameters:

Name Description
name The path of the file.
• @FilesOnDisk(includes, [excludes], [directory]) - Returns a list of files matching the mask on the current server.

## @FilesOnDisk

Returns a list of files matching the mask on the current server.

#### Script usage:

@FilesOnDisk(includes, [excludes], [directory])

#### Parameters:

Name Description
includes Includes
excludes Excludes
directory In Directory

#### Example:

set @ProjectFiles = @FilesOnDisk(*.csproj); # gets project files in working directory

set @NonXDarFiles = @FilesOnDisk(**, **.xdr, $TmpPath); # gets all files except those with an .xdr extension  •$PathCombine(Path1, Path2) - Returns a string containing all of the arguments combined into a complete path.

#### Parameters:

Name Description
Path1 The first path element.
Path2 The second path element.
• $ResolvePath(Path) - Provides an absolute path (terminated with directory separator) based on a relative path and the current working directory; this will provide appropriate directory separators, based on the server in context ##$ResolvePath

Provides an absolute path (terminated with directory separator) based on a relative path and the current working directory; this will provide appropriate directory separators, based on the server in context

$ResolvePath(Path) #### Parameters: Name Description Path path #### Example: $ResolvePath(C:\MyDirectory) -> C:\MyDirectory\
$ResolvePath() -> {WorkingDirectory}$ResolvePath(my\path/to/directory) -> {WorkingDirectory}/my/path/to/directory (on Linux)
$ResolvePath(my\path/to/directory) -> {WorkingDirectory}\my\path\to\directory (on Windows)$ResolvePath(~\path) -> {ExecutionDirectory}\path

• $Date([Format]) - Returns the current date and time of the local timezone in the specified .NET datetime format string, or ISO 8601 format (yyyy-MM-ddTHH:mm:ss) if no format is specified. ##$Date

Returns the current date and time of the local timezone in the specified .NET datetime format string, or ISO 8601 format (yyyy-MM-ddTHH:mm:ss) if no format is specified.

$Date([Format]) #### Parameters: Name Description Format An optional .NET datetime format string. #### See also: #### Example: # format strings taken from https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx set$OtterScript = >>
Now: $Date UTC Now:$DateUtc

Custom: $Date(hh:mm:ss.f) RFC1123:$Date(r)
Sortable: $Date(s) Short time:$Date(t)
>>;

set $Result =$Eval($OtterScript); Log-Information$Result;

• $DateUtc([Format]) - Returns the current UTC date and time in the specified .NET datetime format string, or ISO 8601 format (yyyy-MM-ddTHH:mm:ss) if no format is specified. ##$DateUtc

Returns the current UTC date and time in the specified .NET datetime format string, or ISO 8601 format (yyyy-MM-ddTHH:mm:ss) if no format is specified.

$DateUtc([Format]) #### Parameters: Name Description Format An optional .NET datetime format string. #### See also: #### Example: # format strings taken from https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx set$OtterScript = >>
Now: $Date UTC Now:$DateUtc

Custom: $Date(hh:mm:ss.f) RFC1123:$Date(r)
Sortable: $Date(s) Short time:$Date(t)
>>;

set $Result =$Eval($OtterScript); Log-Information$Result;

• $DockerExePath - (no description ##$DockerExePath

(none)

$DockerExePath • Eval(Text) - Performs variable substitution and function evaluation for arbitrary text. ## Eval Performs variable substitution and function evaluation for arbitrary text. #### Script usage: Eval(Text) #### Parameters: Name Description Text The text to process. #### Example: # format strings taken from https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx set$OtterScript = >>
Now: $Date UTC Now:$DateUtc

Custom: $Date(hh:mm:ss.f) RFC1123:$Date(r)
Sortable: $Date(s) Short time:$Date(t)
>>;

set $Result =$Eval($OtterScript); Log-Information$Result;

• $MSBuildToolsPath - The directory of the MSBuild tools, typically in 'C:\Program Files (x86)\MSBuild\{ToolsVersion}\Bin'; if empty, the MSBuildToolsPath registry value under SOFTWARE\Microsoft\MSBuild\ToolsVersions will be used. ##$MSBuildToolsPath

The directory of the MSBuild tools, typically in 'C:\Program Files (x86)\MSBuild\{ToolsVersion}\Bin'; if empty, the MSBuildToolsPath registry value under SOFTWARE\Microsoft\MSBuild\ToolsVersions will be used.

#### Script usage:

$MSBuildToolsPath •$PromotionComments([StageName], [BuildNumber], [ReleaseNumber], [ApplicationName]) - Returns the comments for the specified promotion, or the promotion in the current context if values are not specified.

#### Parameters:

Name Description
StageName Stage Name
BuildNumber Build Number
ReleaseNumber Release Number
ApplicationName Application Name

#### Example:

# Stores comments from the current promotion in a variable
set $comments =$PromotionComments;
• @Range(Start, Count) - Returns a range of integers starting from a specified value.

## @Range

Returns a range of integers starting from a specified value.

#### Script usage:

@Range(Start, Count)

#### Parameters:

Name Description
Start The first integer of the sequence.
Count The number of integers to return.
• $SpecialWindowsPath(Name) - Returns the full path of a special directory on a Windows system. ##$SpecialWindowsPath

Returns the full path of a special directory on a Windows system.

• $DefaultGitExePath - The path to the git executable to use for git operations; if not specified, a built-in library is used ##$DefaultGitExePath

The path to the git executable to use for git operations; if not specified, a built-in library is used

#### Script usage:

$DefaultGitExePath •$DefaultGitExePath - The path to the git executable to use for git operations; if not specified, a built-in library is used

• $DefaultGitExePath - The path to the git executable to use for git operations; if not specified, a built-in library is used ##$DefaultGitExePath

The path to the git executable to use for git operations; if not specified, a built-in library is used

#### Parameters:

Name Description
Text The text to encode.
• $ToJson(data) - Converts an OtterScript value to JSON. ##$ToJson

Converts an OtterScript value to JSON.

• $SHEval(ScriptText) - Returns the output of a shell script. ##$SHEval

Returns the output of a shell script.

$SHEval(ScriptText) #### Parameters: Name Description ScriptText The shell script to execute. This should be an expression. #### Example: # set the$NextYear variable to the value of... next year
set $ShellScript = >> date -d next-year +%Y >>; set$NextYear = $SHEval($ShellScript);

#### Parameters:

Name Description
List The list.
• $ListIndexOf(List, Item) - Finds the index of an item in a list. Finding the first item in a list returns 0, and finding an item not present in the list returns -1. ##$ListIndexOf

Finds the index of an item in a list. Finding the first item in a list returns 0, and finding an item not present in the list returns -1.

#### Parameters:

Name Description
Arg1 The left-hand side of the comparison.
Operator One of: <, >, <=, >=, =, !=
Arg2 The right-hand side of the comparison.
AsNumber Override number detection. True causes an error if the arguments cannot be parsed as numbers. False always compares them as strings.
• $Decrement(value, [amount]) - Returns a string that contains the result of decrementing a value. ##$Decrement

Returns a string that contains the result of decrementing a value.

#### Parameters:

Name Description
value The value to increment.
amount The amount that will be added to the value. If not specified, 1 is used.

• $NuGetExePath - The path to the nuget.exe client. When not specified, the included nuget.exe client is used. ##$NuGetExePath

The path to the nuget.exe client. When not specified, the included nuget.exe client is used.

$NuGetExePath ## Packages •$PackageHash(packageName, [sourceName]) - Gets the hex-encoded SHA1 hash of a package. The hash is from the version of the package associated with the current build.

#### Parameters:

Name Description
packageName Package Name
sourceName Source Name
• $PackageProperty(packageName, packageProperty, [sourceName]) - Gets a value from the metadata of a package. The property is from the version of the package associated with the current build. ##$PackageProperty

Gets a value from the metadata of a package. The property is from the version of the package associated with the current build.

#### Parameters:

Name Description
packageName Package Name
part The version part, one of: 'full' (default), 'stable', 'pre-release', 'build'
sourceName The package source name; defaults to searching all package sources.

• $PipelineName - name of the pipeline in context ##$PipelineName

name of the pipeline in context

#### Script usage:

$PipelineName •$PipelineStageName - name of the pipeline stage in context

• $PSCredential(UserName, [Password]) - Returns a PSCredential object that can be passed to PowerShell scripts. ##$PSCredential

Returns a PSCredential object that can be passed to PowerShell scripts.

$PSCredential(UserName, [Password]) #### Parameters: Name Description UserName The user name of the PSCredential object, or a UsernamePassword credential. Password The password of the PSCredential object. #### Example: # convert user and password to a PSCredential object PSCall MyPowerShellScript ( Credentials:$PSCredential(user, password)
);

• PSEval(ScriptText) - Returns the result of a PowerShell script.

## PSEval

Returns the result of a PowerShell script.

#### Script usage:

PSEval(ScriptText)

#### Parameters:

Name Description
ScriptText The PowerShell script to execute. This should be an expression.

#### Example:

# set the $NextYear variable to the value of... next year set$PowershellScript = >>
(Get-Date).year + 1
>>;

set $NextYear =$PSEval($PowershellScript); Log-Information$NextYear;


• $CompareReleaseSequence(operator, releaseNum1, [releaseNum2]) - compares the release number of the current application with a specified release number ##$CompareReleaseSequence

compares the release number of the current application with a specified release number

#### Parameters:

Name Description
lastReleaseNumber The release number to increment.
releaseNumberScheme MajorMinor, MajorMinorRevision, or DateBased. If not specified, uses the release number scheme of the current application.
• $PreviousReleaseNumber([ReleaseNumber], [ApplicationName]) - release number of the last deployed release, relative to the specified or current release ##$PreviousReleaseNumber

release number of the last deployed release, relative to the specified or current release

#### Parameters:

Name Description
ReleaseNumber Release Number
ApplicationName Application Name
• $ReleaseNumber - release number of the current release ##$ReleaseNumber

release number of the current release

#### Script usage:

$ReleaseNumber •$ReleaseNumberPart(Part, [ReleaseNumber]) - a part (major, minor, build, revision) of the current or specified release number

#### Parameters:

Name Description
Part Must be "major" or "1", "minor" or "2", "build" or "3" , "revision" or "4"
ReleaseNumber Release Number
• ReleaseVariable(VariableName, [ReleaseNumber], [ApplicationName]) - Gets the value of a variable defined on a release.

## ReleaseVariable

Gets the value of a variable defined on a release.

#### Script usage:

ReleaseVariable(VariableName, [ReleaseNumber], [ApplicationName])

#### Parameters:

Name Description
VariableName Variable Name
ReleaseNumber Release Number
ApplicationName Application Name

## Servers

• @AcquiredServers(Role) - list of all of the servers acquired for a specified role

## @AcquiredServers

list of all of the servers acquired for a specified role

#### Script usage:

@AcquiredServers(Role)

#### Parameters:

Name Description
Role The name of the server role.
• @AllEnvironments - Returns a list of all environments.

## @AllEnvironments

Returns a list of all environments.

#### Script usage:

@AllEnvironments

#### Example:

# log all environments in context to the execution log
foreach $Env in @AllEnvironments { Log-Information$Env;
}

• @AllRoles - Returns a list of all server roles.

## @AllRoles

Returns a list of all server roles.

#### Script usage:

@AllRoles

#### Example:

# log all server roles in context to the execution log
foreach $Role in @AllRoles { Log-Information$Role;
}

• @AllServers([IncludeInactive]) - Returns a list of all servers.

## @AllServers

Returns a list of all servers.

#### Script usage:

@AllServers([IncludeInactive])

#### Parameters:

Name Description
IncludeInactive If true, include servers marked as inactive.

#### Example:

# log all servers in context to the execution log
foreach $Server in @AllServers { Log-Information$Server;
}

• $EnvironmentVariable(EnvironmentVariableName) - Returns the value of the specified environment variable on the current server. ##$EnvironmentVariable

Returns the value of the specified environment variable on the current server.


• $RoleName - name of the current server role in context ##$RoleName

name of the current server role in context

#### Script usage:

$RoleName •$ServerName - name of the current server in context

## $ServerName name of the current server in context #### Script usage: $ServerName
• @ServersInEnvironment([EnvironmentName], [IncludeInactive]) - Returns a list of all the servers in the specified environment name.

## @ServersInEnvironment

Returns a list of all the servers in the specified environment name.

#### Script usage:

@ServersInEnvironment([EnvironmentName], [IncludeInactive])

#### Parameters:

Name Description
EnvironmentName The name of the evironment. If not supplied, the current environment in context will be used.
IncludeInactive If true, include servers marked as inactive.
• @ServersInRole([RoleName], [IncludeInactive]) - Returns a list of servers in the specified role.

## @ServersInRole

Returns a list of servers in the specified role.

#### Script usage:

@ServersInRole([RoleName], [IncludeInactive])

#### Parameters:

Name Description
RoleName The name of the server role. If not supplied, the current role in context will be used.
IncludeInactive If true, include servers marked as inactive.
• @ServersInRoleAndEnvironment([RoleName], [EnvironmentName], [IncludeInactive]) - Returns a list of all the servers in the specified role and environment name.

## @ServersInRoleAndEnvironment

Returns a list of all the servers in the specified role and environment name.

#### Script usage:

@ServersInRoleAndEnvironment([RoleName], [EnvironmentName], [IncludeInactive])

#### Parameters:

Name Description
RoleName The name of the server role. If not supplied, the current role in context will be used.
EnvironmentName The name of the evironment. If not supplied, the current environment in context will be used.
IncludeInactive If true, include servers marked as inactive.

• $Coalesce - Returns the first argument which does not contain only whitespace. ##$Coalesce

Returns the first argument which does not contain only whitespace.

#### Script usage:

$Coalesce •$HtmlEncode(Text) - Encodes a string for use in HTML.

#### Parameters:

Name Description
Text The text to encode.
• $Join(Separator, Values) - Concatenates all elements of a list into a string using a specified separator. ##$Join

Concatenates all elements of a list into a string using a specified separator.

#### Parameters:

Name Description
Text Text
• $MatchesRegex(Text, RegexPattern) - Returns true when the specified text matches the specified pattern; otherwise returns false. ##$MatchesRegex

Returns true when the specified text matches the specified pattern; otherwise returns false.

#### Parameters:

Name Description
WindowsOrLinux Must be either "windows", "linux", or "current". The default value is "current" for the current server.
• PadLeft(Text, Length, [PadCharacter]) - Returns a new string that right-aligns the characters in this instance by padding them on the left with a specified character, for a specified total length. ##PadLeft

Returns a new string that right-aligns the characters in this instance by padding them on the left with a specified character, for a specified total length.

#### Parameters:

Name Description
Text The input string.
Length The length of the string to return.
PadCharacter The character to be inserted as padding. The default is a space.
• @RegexFind(Text, MatchExpression, [MatchGroup]) - Finds all matches of a regular expression in a string, optionally returning only a matched group.

## @RegexFind

Finds all matches of a regular expression in a string, optionally returning only a matched group.

#### Script usage:

@RegexFind(Text, MatchExpression, [MatchGroup])

#### Parameters:

Name Description
Text The string to search for replacements.
MatchExpression The regular expression used to search the first argument.
MatchGroup When specified, the name or index of each match subexpression to return instead of the entire match.
• $RegexReplace(Text, MatchExpression, ReplaceWith) - Searches for and replaces text in a string using a regular expression. ##$RegexReplace

Searches for and replaces text in a string using a regular expression.

#### Parameters:

Name Description
Text The string to search for replacements.
Value The substring to search for in the first argument.
ReplaceWith The substring to replace occurrences of the second parameter with.
IgnoreCase When "true", string comparison will be performed with case insensitivity; the default is "false".
• @Split(Text, Separator, [Count]) - Splits a string into substrings based on a specified separator.

## @Split

Splits a string into substrings based on a specified separator.

#### Script usage:

@Split(Text, Separator, [Count])

#### Parameters:

Name Description
Text String to split.
Separator String that delimits the substrings in this string.
Count The maximum number of substrings to return. If not specified, all substrings are returned.

• $Substring(Text, Offset, [Length]) - Returns a segment of another string. ##$Substring

Returns a segment of another string.

#### Parameters:

Name Description
Text The string to convert to lowercase.

• $ToUpper(Text) - Returns a string with all letters converted to uppercase. ##$ToUpper

Returns a string with all letters converted to uppercase.

#### Parameters:

Name Description
Text The input string.
• $TrimEnd(Text) - Returns a string with all trailing whitespace characters removed, or optionally a set of specified characters. ##$TrimEnd

Returns a string with all trailing whitespace characters removed, or optionally a set of specified characters.

#### Parameters:

Name Description
Text The input string.
• $UrlEncode(Text) - Escapes a string for use in a URL. ##$UrlEncode

Escapes a string for use in a URL.

#### Parameters:

Name Description
Text The text to encode.

• $YouTrackStatusFieldName - The name of the custom field used by YouTrack for an issue's status. The default is "State". ##$YouTrackStatusFieldName

The name of the custom field used by YouTrack for an issue's status. The default is "State".

#### Script usage:

$YouTrackStatusFieldName •$YouTrackTypeFieldName - The name of the custom field used by YouTrack for an issue's type. The default is "Type".

• $YouTrackVersionFieldName - The name of the custom field used by YouTrack for an issue's targeted version number. The default is "Fix version". ##$YouTrackVersionFieldName

The name of the custom field used by YouTrack for an issue's targeted version number. The default is "Fix version".

#### Script usage:

\$YouTrackVersionFieldName