コード例 #1
0
def reformat_cmd(text):
    """ reformat the text to be stripped of noise """
    # remove az if there
    text = text.replace('az', '')
    # disregard defaulting symbols
    if text and SELECT_SYMBOL['scope'] == text[0:2]:
        text = text.replace(SELECT_SYMBOL['scope'], "")

    if get_scope():
        text = get_scope() + ' ' + text
    return text
コード例 #2
0
def reformat_cmd(text):
    """ reformat the text to be stripped of noise """
    # remove az if there
    text = text.replace('az', '')
    # disregard defaulting symbols
    if text and SELECT_SYMBOL['scope'] == text[0:2]:
        text = text.replace(SELECT_SYMBOL['scope'], "")

    if get_scope():
        text = get_scope() + ' ' + text
    return text