Skip to content
Snippets Groups Projects
Commit 80b19218 authored by Mayr, Hannes's avatar Mayr, Hannes
Browse files

Mention the export imports functionality in README.

parent e2c0d770
No related branches found
No related tags found
1 merge request!62Export imported modules
Pipeline #883686 passed
......@@ -77,7 +77,7 @@ FIGS_AND_IDS = tagplot(FIGS_AS_LIST, "matplotlib", prefix="XY23_", id_method="ra
### publish()
Save plot, data and measuring script. It is possible to export multiple figures at once.
Save plot, data and measuring script. Modules that are imported in the script which calls plotID are exported to the file "required_imports.txt". These can later be installed via pip. It is possible to export multiple figures at once.
`publish(figs_and_ids, src_datapath, dst_path)`
- *figs_and_ids* must be a PlotIDTransfer object. Therefore, it can be directly passed from tagplot() to publish().
......
......@@ -241,7 +241,7 @@ class PublishOptions:
)
def export_imports(self, file: str) -> None:
"""Export all imported modules in of a python script to file."""
"""Export all imported modules of a python script to file."""
with open(file, "r", encoding="utf-8") as source:
tree = ast.parse(source.read())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment