[ MODULE ] - Utilities.
More...
|
def | createPythonModule (path, name='__init__.py', content=None) |
| Create a Python module with given name in given path. More...
|
|
◆ createPythonModule()
def sPythonUtils.utilitiesLib.createPythonModule |
( |
|
path, |
|
|
|
name = '__init__.py' , |
|
|
|
content = None |
|
) |
| |
Create a Python module with given name in given path.
- Parameters
-
path | [ str | None | in ] - Absolute path where the Python module will be created in. |
name | [ str | None | in ] - Name of the Python module, which will be created. |
content | [ str | None | in ] - Content, which will be written into the file. |
- Exceptions
-
IOError | - If path does not exist. |
IOError | - If a Python module with name in path already exists. |
- Returns
- str - Absolute path of the created Python module.