Rename POWERLINE_THEME_CONFIG to POWERLINE_THEME_OVERRIDES

Ref #1126
This commit is contained in:
ZyX 2015-01-06 21:00:36 +03:00
parent 45ccbee171
commit de064558a1
3 changed files with 4 additions and 4 deletions

View File

@ -80,7 +80,7 @@ are taken from zsh variables.
VALUE}}``. All pairs are then recursively merged into one dictionary and VALUE}}``. All pairs are then recursively merged into one dictionary and
this dictionary is recursively merged with the contents of the file. this dictionary is recursively merged with the contents of the file.
``POWERLINE_THEME_CONFIG`` ``POWERLINE_THEME_OVERRIDES``
Overrides options from :file:`powerline/themes/shell/*.json`. Should be Overrides options from :file:`powerline/themes/shell/*.json`. Should be
a zsh associative array with keys equal to ``THEME_NAME.KEY.NESTED_KEY`` and a zsh associative array with keys equal to ``THEME_NAME.KEY.NESTED_KEY`` and
values being JSON strings. Is processed like the above values being JSON strings. Is processed like the above

View File

@ -41,7 +41,7 @@ class Args(object):
@property @property
def theme_override(self): def theme_override(self):
return get_var_config('POWERLINE_THEME_CONFIG') return get_var_config('POWERLINE_THEME_OVERRIDES')
@property @property
def config_path(self): def config_path(self):

View File

@ -4,7 +4,7 @@ setopt interactivecomments
setopt autonamedirs setopt autonamedirs
if test -z "$POWERLINE_NO_ZSH_ZPYTHON" ; then if test -z "$POWERLINE_NO_ZSH_ZPYTHON" ; then
function set_theme_option() { function set_theme_option() {
POWERLINE_THEME_CONFIG[$1]=$2 POWERLINE_THEME_OVERRIDES[$1]=$2
powerline-reload-config powerline-reload-config
} }
function set_theme() { function set_theme() {
@ -23,7 +23,7 @@ else
} }
fi fi
source powerline/bindings/zsh/powerline.zsh source powerline/bindings/zsh/powerline.zsh
typeset -gA POWERLINE_CONFIG_OVERRIDES POWERLINE_THEME_CONFIG typeset -gA POWERLINE_CONFIG_OVERRIDES POWERLINE_THEME_OVERRIDES
set_theme_option default_leftonly.segment_data.hostname.args.only_if_ssh false set_theme_option default_leftonly.segment_data.hostname.args.only_if_ssh false
set_theme_option default.segment_data.hostname.args.only_if_ssh false set_theme_option default.segment_data.hostname.args.only_if_ssh false
set_theme default_leftonly set_theme default_leftonly