# HG changeset patch # User Mads Kiilerich # Date 1590159250 -7200 # Node ID 04908b44005c0c9c4e5859661be78835050e8879 # Parent 6eb1f66ac23f116392f1c3b9fdf7458ecc15aa3c ini: put kallithea-config version in the ini file it creates (Issue #373) Help keeping track of how the .ini was created. diff -r 6eb1f66ac23f -r 04908b44005c kallithea/bin/kallithea_cli_config.py --- a/kallithea/bin/kallithea_cli_config.py Fri May 22 16:45:09 2020 +0200 +++ b/kallithea/bin/kallithea_cli_config.py Fri May 22 16:54:10 2020 +0200 @@ -62,6 +62,7 @@ """ mako_variable_values = { + 'version': kallithea.__version__, 'git_hook_interpreter': sys.executable, 'user_home_path': os.path.expanduser('~'), 'kallithea_cli_path': cli_base.kallithea_cli_path, diff -r 6eb1f66ac23f -r 04908b44005c kallithea/lib/inifile.py --- a/kallithea/lib/inifile.py Fri May 22 16:45:09 2020 +0200 +++ b/kallithea/lib/inifile.py Fri May 22 16:54:10 2020 +0200 @@ -40,6 +40,7 @@ 'host': '127.0.0.1', 'port': '5000', 'uuid': lambda: 'VERY-SECRET', + 'version': '', } variable_options = { diff -r 6eb1f66ac23f -r 04908b44005c kallithea/lib/paster_commands/template.ini.mako --- a/kallithea/lib/paster_commands/template.ini.mako Fri May 22 16:45:09 2020 +0200 +++ b/kallithea/lib/paster_commands/template.ini.mako Fri May 22 16:54:10 2020 +0200 @@ -1,7 +1,7 @@ ## -*- coding: utf-8 -*- <%text>################################################################################### <%text>################################################################################### -<%text>## Kallithea config file generated with kallithea-config ## +<%text>## Kallithea config file generated with kallithea-config ${'%-24s' % version }## <%text>## ## <%text>## The %(here)s variable will be replaced with the parent directory of this file ## <%text>###################################################################################