From d4180295e3c7d587a28e01aa372cc19f8cbd3120 Mon Sep 17 00:00:00 2001 From: Petr Demin Date: Wed, 17 Jun 2015 17:12:28 +0300 Subject: [PATCH] formulas.jinja: python 2.6 support --- salt/formulas.jinja | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/salt/formulas.jinja b/salt/formulas.jinja index 071312c..599659f 100644 --- a/salt/formulas.jinja +++ b/salt/formulas.jinja @@ -8,8 +8,8 @@ {% set formulas = salt['pillar.get']('salt_formulas:list', {}) %} {%- macro formulas_git_opt(env, opt) -%} -{%- set value = salt['pillar.get']('salt_formulas:git_opts:{}:{}'.format(env, opt), - salt['pillar.get']('salt_formulas:git_opts:default:{}'.format(opt), +{%- set value = salt['pillar.get']('salt_formulas:git_opts:{0}:{1}'.format(env, opt), + salt['pillar.get']('salt_formulas:git_opts:default:{0}'.format(opt), defaults[opt])) -%} {%- if value is mapping -%} {{ value|yaml }} @@ -21,7 +21,7 @@ {%- macro formulas_roots(env) -%} {%- set value = [] -%} {%- for dir in formulas.get(env, []) -%} -{%- do value.append('{}/{}'.format(formulas_git_opt(env, 'basedir'), dir)) -%} +{%- do value.append('{0}/{1}'.format(formulas_git_opt(env, 'basedir'), dir)) -%} {%- endfor -%} {{ value|yaml }} {%- endmacro -%}