Feature Request: Support Default Options for beangulp.Injest()
For import scripts that call beangulp.Injest(), allow them to provide default values for CLI options like downloads and destination.
Example:
ingest = beangulp.Ingest(importers, hooks, {'downloads': './Downloads'})
I originally reported this against beancount. This has become more relevant with beangulp since --downloads has been replaced with a positional parameter, thus it is more difficult to detect its absence in the wrapper without baking in knowledge of all archive options.
An initial pass at this for the src tuple present on each click command. It could probably be expanded to other command line arguments later. It doesnt seem to work for paths starting with ~ though.
https://github.com/alexrkaufman/beangulp/commit/9d1dc88d391f3e7f3b6a235e546cec7bf7b445a7
In my import.py this is what its use looks like.
if __name__ == "__main__":
ingest = beangulp.Ingest(importers, hooks, defaults={"src": "import/"})
ingest()