From: Serge Rehbinder Date: Thu, 29 Sep 2016 10:15:16 +0000 (+0200) Subject: add commentaries X-Git-Tag: 5.0.0a1~91 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6720a60c26239839c847ab21df597316249df018;p=tools%2Fsat.git add commentaries --- diff --git a/commands/base.py b/commands/base.py index 9f1ac4f..cb40711 100644 --- a/commands/base.py +++ b/commands/base.py @@ -26,6 +26,15 @@ parser.add_option('s', 'set', 'string', 'base_path', _('The path directory to use as base.'), None) def set_base(config, path, site_file_path, logger): + """ Edit the site.pyconf file and change the base path + + :param config Config: The global configuration. + :param path src.Path: The path to put in the site.pyconf file. + :param site_file_path Str: The path to the site.pyconf file. + :param logger Logger: The logger instance. + :return: 0 if all is OK, else 1 + :rtype: int + """ # Update the site.pyconf file try: site_pyconf_cfg = src.pyconf.Config(site_file_path) @@ -46,6 +55,11 @@ def set_base(config, path, site_file_path, logger): def display_base_path(config, logger): + """ Display the base path + + :param config Config: The global configuration. + :param logger Logger: The logger instance. + """ info = [(_("Base path"), config.SITE.base)] src.print_info(logger, info)