<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def cmd_string(name, cmd):
 # type: (AName, ACmd) -> ADefine """Define a string parameter coming from a shell command to be used within this YAML file. Trailing newlines will be stripped."""

    value = subprocess.check_output(cmd, shell=True).rstrip("\n")
    return Define(name, value)