babelizer.utils module

babelizer.utils.execute(args)

Run a command through the subprocess module.

Parameters

args (list) – Command and arguments to command.

Returns

results from subprocess.run.

babelizer.utils.get_setup_py_version()

Get babelized package version.

Raises

SetupPyError – if calling python setup.py raises an exception.

Returns

Package version.

Return type

str or None

babelizer.utils.save_files(files)

Generate repository files through a context.

Parameters

files (list of str) – List of path-like objects.

Yields

Generator for repository files.

babelizer.utils.setup_py(*args)

Format the command to build/install the babelized package.

Returns

The build/install command.

Return type

list of str