diff options
author | hut <hut@lepus.uberspace.de> | 2016-06-26 13:43:07 +0200 |
---|---|---|
committer | nfnty <git@nfnty.se> | 2017-01-29 19:32:13 +0100 |
commit | 1df6f2763acc32bc43628bb635025478c85a1f92 (patch) | |
tree | bd9d5541aae23136950aa0bcd8eaaab21acaba76 | |
parent | f557329083d964027d79f4a14e4e2951c11eac4d (diff) | |
download | ranger-1df6f2763acc32bc43628bb635025478c85a1f92.tar.gz |
container.settings: Sane fallback values
-rw-r--r-- | ranger/container/settings.py | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/ranger/container/settings.py b/ranger/container/settings.py index e08f18c6..6e5e44f1 100644 --- a/ranger/container/settings.py +++ b/ranger/container/settings.py @@ -83,13 +83,13 @@ ALLOWED_SETTINGS = { } ALLOWED_VALUES = { - 'confirm_on_delete': ['always', 'multiple', 'never'], + 'confirm_on_delete': ['multiple', 'always', 'never'], 'line_numbers': ['false', 'absolute', 'relative'], 'preview_images_method': ['w3m', 'iterm2', 'urxvt', 'urxvt-full'], - 'vcs_backend_bzr': ['enabled', 'local', 'disabled'], - 'vcs_backend_git': ['enabled', 'local', 'disabled'], - 'vcs_backend_hg': ['enabled', 'local', 'disabled'], - 'vcs_backend_svn': ['enabled', 'local', 'disabled'], + 'vcs_backend_bzr': ['disabled', 'local', 'enabled'], + 'vcs_backend_git': ['enabled', 'disabled', 'local'], + 'vcs_backend_hg': ['disabled', 'local', 'enabled'], + 'vcs_backend_svn': ['disabled', 'local', 'enabled'], 'viewmode': ['miller', 'multipane'], } @@ -116,6 +116,10 @@ class Settings(SignalDispatcher, FileManagerAware): priority=SIGNAL_PRIORITY_SANITIZE) self.signal_bind('setopt.' + name, self._raw_set_with_signal, priority=SIGNAL_PRIORITY_SYNC) + for name, values in ALLOWED_VALUES.items(): + assert values + assert name in ALLOWED_SETTINGS + self._raw_set(name, values[0]) def _sanitize(self, signal): name, value = signal.setting, signal.value |