Created upgrade script to 1.4.dev4

This commit is contained in:
Ohm Patel
2015-12-10 13:05:32 -06:00
parent 7461c2381e
commit 184ecfa554
2 changed files with 11 additions and 1 deletions

View File

@@ -22,7 +22,7 @@ import re
PICARD_APP_NAME = "Picard"
PICARD_ORG_NAME = "MusicBrainz"
PICARD_VERSION = (1, 4, 0, 'dev', 3)
PICARD_VERSION = (1, 4, 0, 'dev', 4)
# optional build version
# it should be in the form '<platform>_<YYMMDDHHMMSS>'

View File

@@ -164,6 +164,15 @@ def upgrade_to_v1_4_0_dev_3():
_s['ca_providers'] = newopts
def upgrade_to_v1_4_0_dev_4():
"""Adds trailing comma to default file names for scripts"""
old_opt = "$if($ne(%albumartist%,),%album%/)"
new_opt = "$if($ne(%albumartist%,),%album%/,)"
if old_opt in _s:
_s[new_opt] = _s.value(old_opt, config.BoolOption, True)
_s.remove(old_opt)
def upgrade_config():
cfg = config._config
cfg.register_upgrade_hook(upgrade_to_v1_0_0_final_0)
@@ -173,4 +182,5 @@ def upgrade_config():
cfg.register_upgrade_hook(upgrade_to_v1_3_0_dev_4)
cfg.register_upgrade_hook(upgrade_to_v1_4_0_dev_2)
cfg.register_upgrade_hook(upgrade_to_v1_4_0_dev_3)
cfg.register_upgrade_hook(upgrade_to_v1_4_0_dev_4)
cfg.run_upgrade_hooks(log.debug)