diff options
| author | mikeos <mike.osipov@gmail.com> | 2013-09-22 19:21:30 +0400 |
|---|---|---|
| committer | mikeos <mike.osipov@gmail.com> | 2013-09-22 19:21:30 +0400 |
| commit | d5cc80059218e1b66749b0b61c722d0480e03a88 (patch) | |
| tree | f3ff2c9d63db02f62c46011312826197bc7ea43b | |
| parent | 524948282b48867cdda2f43a512e872413752c32 (diff) | |
add --year option (alias for --date)
| -rwxr-xr-x | cutter | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -185,11 +185,14 @@ def parse_args(): parser.add_option_group(format) tag = OptionGroup(parser, "Tag options") - tag_options = ["album", "artist", "date", "genre", + tag_options = ["album", "artist", ("date", "year"), "genre", "comment", "composer", "albumartist"] for opt in tag_options: - tag.add_option("--" + opt, dest=opt, default="") + if type(opt) in (list, tuple): + tag.add_option(*["--" + s for s in opt], dest=opt[0], default="") + else: + tag.add_option("--" + opt, dest=opt, default="") parser.add_option_group(tag) |
