diff --git a/favro_sync/__init__.py b/favro_sync/__init__.py index 0c45c69..9025fca 100644 --- a/favro_sync/__init__.py +++ b/favro_sync/__init__.py @@ -11,11 +11,21 @@ Uses [`python-fuse`](https://github.com/libfuse/python-fuse) library. Limitations: -- Only works for TODO files. +- Only cards in todolist is fetched at the moment. - Doesn't include title anywhere. - Tasks cannot be updated or changed. +- Slow, due to inefficient use of caches. A more complete implementation will probably require a Markdown parser, to parse the saved input, and distribute it across the various Card fields (card name, description, tasks, etc...) + +## Usage + +1. Install dependencies `pip install -r requirements.txt` +2. Setup [secrets](https://gitfub.space/Jmaa/secret_loader]): `FAVRO_ORGANIZATION_ID`, `FAVRO_USERNAME`, `FAVRO_PASSWORD`. +3. Run `python -m favro_sync `. Use the `--help` argument to get an + overview of all supported flags (there is a lot, because + [`python-fuse`](https://github.com/libfuse/python-fuse) implements a whole + bunch automatically.) """ diff --git a/favro_sync/__main__.py b/favro_sync/__main__.py index 67c735c..4d4ee48 100644 --- a/favro_sync/__main__.py +++ b/favro_sync/__main__.py @@ -1,4 +1,6 @@ +import tempfile + import requests_cache import secret_loader @@ -14,9 +16,7 @@ def main(): read_only = False - # with tempfile.TemporaryDirectory(prefix='favro_sync_') as tmpdirname: - tmpdirname = './output' # TODO - if True: + with tempfile.TemporaryDirectory(prefix='favro_sync_') as tmpdirname: session = requests_cache.CachedSession( tmpdirname + '/http-cache.sqlite', expire_after=360, )