easybuild.tools.options module¶
Command line options for eb
Authors:
- Stijn De Weirdt (Ghent University)
- Dries Verdegem (Ghent University)
- Kenneth Hoste (Ghent University)
- Pieter De Baets (Ghent University)
- Jens Timmerman (Ghent University)
- Toon Willems (Ghent University)
- Ward Poelmans (Ghent University)
- Damian Alvarez (Forschungszentrum Juelich GmbH)
- Maxime Boissonneault (Compute Canada)
-
class
easybuild.tools.options.EasyBuildOptions(*args, **kwargs)¶ Bases:
easybuild.base.generaloption.GeneralOptionEasybuild generaloption class
-
ALLOPTSMANDATORY= False¶
-
CONFIGFILES_RAISE_MISSING= True¶
-
DEFAULT_CONFIGFILES= []¶
-
DEFAULT_LOGLEVEL= 'INFO'¶
-
VERSION= 'This is EasyBuild 4.7.0 (framework: 4.7.0, easyblocks: 4.7.0) on host build-19626103-project-22310-boegel-eb.'¶
-
avail_list(name, items)¶ Show list of available values passed by argument.
-
avail_repositories()¶ Show list of known repository types.
-
basic_options()¶ basic runtime options
-
config_options()¶
-
container_options()¶
-
easyblock_options()¶
-
easyconfig_options()¶
-
get_cfg_opt_abs_path(opt_name, path)¶ Get path value of configuration option as absolute path.
-
github_options()¶ GitHub integration configuration options.
-
informative_options()¶
-
job_options()¶ Option related to –job.
-
override_options()¶
-
package_options()¶
-
postprocess()¶ Do some postprocessing, in particular print stuff
-
regtest_options()¶ Regression test configuration options.
-
show_config()¶ Show specified EasyBuild configuration, relative to default EasyBuild configuration.
-
show_default_configfiles()¶ Show list of default config files.
-
show_default_moduleclasses()¶ Show list of default moduleclasses and description.
-
show_system_info()¶ Show system information.
-
software_options()¶
-
unittest_options()¶
-
validate()¶ Additional validation of options
-
-
easybuild.tools.options.check_root_usage(allow_use_as_root=False)¶ Check whether we are running as root, and act accordingly
Parameters: allow_use_as_root – allow use of EasyBuild as root (but do print a warning when doing so)
-
easybuild.tools.options.cleanup_and_exit(tmpdir)¶ Clean up temporary directory and exit.
Parameters: tmpdir – path to temporary directory to clean up
-
easybuild.tools.options.opts_dict_to_eb_opts(args_dict)¶ Convert a dictionary with configuration option values to command-line options for the ‘eb’ command. Can by used to convert e.g. easyconfig-specific options from an easystack file to a list of strings that can be fed into the EasyBuild option parser :param args_dict: dictionary with configuration option values :return: a list of strings representing command-line options for the ‘eb’ command
-
easybuild.tools.options.parse_external_modules_metadata(cfgs)¶ Parse metadata for external modules.
Parameters: cfgs – list of (glob patterns for) paths to config files providing metadata for external modules Returns: parsed metadata for external modules
-
easybuild.tools.options.parse_options(args=None, with_include=True)¶ wrapper function for option parsing
-
easybuild.tools.options.pretty_print_opts(opts_dict)¶ Pretty print options dict.
Parameters: opts_dict – dictionary with option names as keys, and (value, location) tuples as values
-
easybuild.tools.options.process_software_build_specs(options)¶ Create a dictionary with specified software build options. The options arguments should be a parsed option list (as delivered by parse_options(args).options)
-
easybuild.tools.options.set_tmpdir(tmpdir=None, raise_error=False)¶ Set temporary directory to be used by tempfile and others.
-
easybuild.tools.options.set_up_configuration(args=None, logfile=None, testing=False, silent=False, reconfigure=False)¶ Set up EasyBuild configuration, by parsing configuration settings & initialising build options.
Parameters: - args – command line arguments to take into account when parsing the EasyBuild configuration settings
- logfile – log file to use
- testing – enable testing mode
- silent – stay silent (no printing)
- reconfigure – reconfigure singletons that hold configuration dictionaries. Use with care: normally,
configuration shouldn’t be changed during a run. Exceptions are when looping over items in EasyStack files
-
easybuild.tools.options.terminal_supports_colors(stream)¶
-
easybuild.tools.options.use_color(colorize, stream=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='UTF-8'>)¶ Return
TrueorFalsedepending on whether ANSI color escapes are to be used when printing to stream.The colorize argument can take the three values
fancylogger.Colorize.AUTO/.ALWAYS/.NEVER, see the--coloroption for their meaning.