https://github.com/korcankaraokcu/unotagger
A simple tagging library for documenting python scripts
https://github.com/korcankaraokcu/unotagger
library libreoffice python3 taggingtools unotools
Last synced: 8 months ago
JSON representation
A simple tagging library for documenting python scripts
- Host: GitHub
- URL: https://github.com/korcankaraokcu/unotagger
- Owner: korcankaraokcu
- License: gpl-3.0
- Created: 2017-07-19T14:05:38.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2017-08-02T11:25:46.000Z (almost 9 years ago)
- Last Synced: 2025-04-30T22:12:25.266Z (about 1 year ago)
- Topics: library, libreoffice, python3, taggingtools, unotools
- Language: Python
- Homepage:
- Size: 25.4 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: COPYING
- Authors: AUTHORS
Awesome Lists containing this project
README
# UnoTagger
A simple tagging library for documenting python scripts
## How to install
UnoTagger only requires unotools, assuming that you already have libreoffice installed:
```sudo pip3 install unotools```
If you don't have libreoffice or unolibs by default, execute this to install all the required tools from scratch:
```sudo aptitude install -y libreoffice libreoffice-script-provider-python uno-libs3 python3-uno python3```
## How to use
Startup libreoffice:
```soffice --accept='socket,host=localhost,port=8100;urp;StarOffice.Service'```
Use UnoTagger's ```create_tag_documents()``` function in your project.
Run this command for demonstration:
```python3 test.py```
### Pros
- Module based, you don't have to pass source file paths as the parameter
- Can create documents based on multiple modules
- Ability to search through function names
- Can document variables (check ```unotagger.get_comments_of_variables()``` function for more information)
### Cons
- Can only tag functions and variables in a module. Doesn't support classes or inline functions since it iterates on ```dir(module)``` only once. Iteration on demand can be achieved by modifying the functions in unotagger.py slightly. You can also choose to create a generator out of them.