update kobuddy paths
This commit is contained in:
parent
ffe11210cc
commit
4b751e0408
2 changed files with 19 additions and 3 deletions
|
@ -1,7 +1,7 @@
|
||||||
Python interface into my life
|
Python interface into my life
|
||||||
|
|
||||||
|
|
||||||
# Usage
|
# Setting up
|
||||||
```
|
```
|
||||||
cp with_my.example with_my
|
cp with_my.example with_my
|
||||||
|
|
||||||
|
@ -9,3 +9,9 @@ cp with_my.example with_my
|
||||||
vim with_my
|
vim with_my
|
||||||
```
|
```
|
||||||
TODO add instructions to try it?
|
TODO add instructions to try it?
|
||||||
|
|
||||||
|
|
||||||
|
# Usage example
|
||||||
|
```
|
||||||
|
with_my python3 -c 'import my.books.kobo as kobo; print(kobo.get_todos())'
|
||||||
|
```
|
||||||
|
|
|
@ -1,6 +1,16 @@
|
||||||
from my.ext.kobuddy import *
|
from functools import lru_cache
|
||||||
|
|
||||||
set_databases('/L/backups/kobo')
|
from .. import paths
|
||||||
|
|
||||||
|
@lru_cache()
|
||||||
|
def kobuddy_module():
|
||||||
|
from kython import import_from
|
||||||
|
return import_from(paths.kobuddy.repo, 'kobuddy')
|
||||||
|
|
||||||
|
kobuddy = kobuddy_module()
|
||||||
|
from kobuddy import *
|
||||||
|
|
||||||
|
set_databases(paths.kobuddy.export_dir)
|
||||||
|
|
||||||
def get_todos():
|
def get_todos():
|
||||||
def with_todo(ann):
|
def with_todo(ann):
|
||||||
|
|
Loading…
Add table
Reference in a new issue