def parse_argv():
parser = argparse.ArgumentParser(description='<STR_LIT>'<EOL>'<STR_LIT>')<EOL>parser.add_argument('<STR_LIT>', '<STR_LIT>', help='<STR_LIT>',<EOL>type=int, metavar='<STR_LIT:N>', default=<NUM_LIT:1>)<EOL>parser.add_argument('<STR_LIT>', '<STR_LIT>', help='<STR_LIT>'<EOL>'<STR_LIT>', action='<STR_LIT:store_true>')<EOL>parser.add_argument('<STR_LIT>', '<STR_LIT>', help='<STR_LIT>'<EOL>'<STR_LIT>', action='<STR_LIT:store_true>')<EOL>parser.add_argument('<STR_LIT>', '<STR_LIT>', help='<STR_LIT>'<EOL>'<STR_LIT>', action='<STR_LIT:count>')<EOL>parser.add_argument('<STR_LIT>', '<STR_LIT>', help='<STR_LIT>',<EOL>action='<STR_LIT:store_true>')<EOL>group = parser.add_mutually_exclusive_group()<EOL>group.add_argument('<STR_LIT>', '<STR_LIT>', help='<STR_LIT>'<EOL>'<STR_LIT>', metavar='<STR_LIT:path>', nargs='<STR_LIT:?>', const='<STR_LIT:.>')<EOL>group.add_argument('<STR_LIT>', help='<STR_LIT>'<EOL>'<STR_LIT>', type=str)<EOL>parser.add_argument('<STR_LIT>', help='<STR_LIT>',<EOL>nargs='<STR_LIT:*>')<EOL>args = parser.parse_args()<EOL>CONFIG['<STR_LIT>'] = args.overwrite<EOL>CONFIG['<STR_LIT>'] = args.stats<EOL>if args.verbose is None or args.verbose == <NUM_LIT:0>:<EOL><INDENT>logger.setLevel(logging.CRITICAL)<EOL><DEDENT>elif args.verbose == <NUM_LIT:1>:<EOL><INDENT>logger.setLevel(logging.INFO)<EOL><DEDENT>else:<EOL><INDENT>logger.setLevel(logging.DEBUG)<EOL><DEDENT>if args.jobs <= <NUM_LIT:0>:<EOL><INDENT>msg = '<STR_LIT>'<EOL>parser.error(msg)<EOL><DEDENT>else:<EOL><INDENT>CONFIG['<STR_LIT>'] = args.jobs<EOL><DEDENT>songs = set()<EOL>if args.from_file:<EOL><INDENT>songs = load_from_file(args.from_file)<EOL>if not songs:<EOL><INDENT>raise ValueError('<STR_LIT>')<EOL><DEDENT><DEDENT>elif args.recursive:<EOL><INDENT>mp3files = glob.iglob(args.recursive + '<STR_LIT>', recursive=True)<EOL>songs = set(Song.from_filename(f) for f in mp3files)<EOL><DEDENT>elif args.songs:<EOL><INDENT>if os.path.exists(args.songs[<NUM_LIT:0>]):<EOL><INDENT>parser = Song.from_filename<EOL><DEDENT>else:<EOL><INDENT>parser = Song.from_string<EOL><DEDENT>songs.update(map(parser, args.songs))<EOL><DEDENT>else:<EOL><INDENT>songs.add(get_current_song())<EOL><DEDENT>return songs.difference({None})<EOL>
Parse command line arguments. Settings will be stored in the global
variables declared above.