def cli():
    """Run the command line interface."""
    args = docopt.docopt(__doc__, version=__VERSION__)
    secure = args['--secure']
    numberofwords = int(args['<numberofwords>'])

    dictpath = args['--dict']
    if dictpath is not None:
        dictfile = open(dictpath)
    else:
        dictfile = load_stream('words.txt')
    with dictfile:
        wordlist = read_wordlist(dictfile)

    words = generate_words(numberofwords, wordlist, secure=secure)
    print(' '.join(words))
def cli ( ) : args = docopt . docopt ( __doc__ , version = __VERSION__ ) secure = args [ '--secure' ] numberofwords = int ( args [ '<numberofwords>' ] ) dictpath = args [ '--dict' ] if dictpath is not None : dictfile = open ( dictpath ) else : dictfile = load_stream ( 'words.txt' ) with dictfile : wordlist = read_wordlist ( dictfile ) words = generate_words ( numberofwords , wordlist , secure = secure ) print ( ' ' . join ( words ) )
Run the command line interface.