def _cat_parse_args(args): out = {'number_nonblank': False, 'number_all': False, 'squeeze_blank': False, 'show_ends': False} if '--help' in args: return arg_handler(args, out, '-b', 'number_nonblank', True, '--number-nonblank') arg_handler(args, out, '-n', 'number_all', True, '--number') arg_handler(args, out, '-E', 'show_ends', True, '--show-ends') arg_handler(args, out, '-s', 'squeeze_blank', True, '--squeeze-blank') arg_handler(args, out, '-T', 'show_tabs', True, '--show-tabs') return out
def _cat_parse_args(args): out = { "number_nonblank": False, "number_all": False, "squeeze_blank": False, "show_ends": False, } if "--help" in args: return arg_handler(args, out, "-b", "number_nonblank", True, "--number-nonblank") arg_handler(args, out, "-n", "number_all", True, "--number") arg_handler(args, out, "-E", "show_ends", True, "--show-ends") arg_handler(args, out, "-s", "squeeze_blank", True, "--squeeze-blank") arg_handler(args, out, "-T", "show_tabs", True, "--show-tabs") return out