forked from gaugendre/ofx-processor
Compare commits
10 commits
Author | SHA1 | Date | |
---|---|---|---|
d7a2c10271 | |||
26c8f17861 | |||
56564069c3 | |||
7ed84a47fe | |||
8cd40d71f6 | |||
b9f851322e | |||
7f53a5e3e1 | |||
c55de64c96 | |||
f5a3c5ce58 | |||
0fa878e88c |
7 changed files with 18 additions and 8 deletions
|
@ -3,7 +3,7 @@ WORKDIR /app
|
|||
RUN apt-get update && apt-get install -y wget
|
||||
ARG GECKODRIVER_VERSION="v0.30.0"
|
||||
ARG GECKODRIVER_FILENAME="geckodriver-$GECKODRIVER_VERSION-linux64"
|
||||
RUN wget -q https://github.com/mozilla/geckodriver/releases/download/v0.30.0/$GECKODRIVER_FILENAME.tar.gz && tar xvf $GECKODRIVER_FILENAME.tar.gz && rm $GECKODRIVER_FILENAME.tar.gz
|
||||
RUN wget -q https://github.com/mozilla/geckodriver/releases/download/$GECKODRIVER_VERSION/$GECKODRIVER_FILENAME.tar.gz && tar xvf $GECKODRIVER_FILENAME.tar.gz && rm $GECKODRIVER_FILENAME.tar.gz
|
||||
|
||||
FROM python:3.10-slim-bullseye as final
|
||||
RUN apt-get update && apt-get install -y firefox-esr
|
||||
|
|
|
@ -53,3 +53,6 @@ git commit
|
|||
inv tag <version>
|
||||
inv publish publish-docker
|
||||
```
|
||||
|
||||
# Reuse
|
||||
If you do reuse my work, please consider linking back to this repository 🙂
|
|
@ -31,7 +31,7 @@ class LclDownloader:
|
|||
"browser.helperApps.neverAsk.saveToDisk", "application/x-ofx"
|
||||
)
|
||||
self.selenium = webdriver.Firefox(options=options)
|
||||
self.selenium.implicitly_wait(10)
|
||||
self.selenium.implicitly_wait(30)
|
||||
|
||||
def download(self) -> str:
|
||||
selenium = self.selenium
|
||||
|
|
|
@ -80,7 +80,7 @@ class LclProcessor(OfxBaseProcessor):
|
|||
return ofx
|
||||
|
||||
|
||||
def main(filename, keep, download, send_method):
|
||||
def main(filename, keep, download, send_method, push_to_ynab):
|
||||
"""Import LCL bank statement (OFX file)."""
|
||||
if download:
|
||||
if filename:
|
||||
|
@ -93,4 +93,5 @@ def main(filename, keep, download, send_method):
|
|||
processor = LclProcessor(filename)
|
||||
if send_method:
|
||||
processor.send_reconciled_amount(send_method)
|
||||
if push_to_ynab:
|
||||
processor.push_to_ynab(keep)
|
||||
|
|
|
@ -38,6 +38,13 @@ ARG_TO_OPTION = {
|
|||
default="",
|
||||
show_default=True,
|
||||
),
|
||||
"push_to_ynab": click.option(
|
||||
"push_to_ynab",
|
||||
"--push/--no-push",
|
||||
help="Push the data to YNAB.",
|
||||
default=True,
|
||||
show_default=True,
|
||||
),
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,9 +1,8 @@
|
|||
[tool.poetry]
|
||||
name = "ofx-processor"
|
||||
version = "4.0.1"
|
||||
version = "4.1.0"
|
||||
description = "Personal ofx processor"
|
||||
readme = "README.md"
|
||||
license = "Unlicense"
|
||||
authors = ["Gabriel Augendre <gabriel@augendre.info>"]
|
||||
homepage = "https://git.augendre.info/gaugendre/ofx-processor"
|
||||
repository = "https://git.augendre.info/gaugendre/ofx-processor"
|
||||
|
|
4
tasks.py
4
tasks.py
|
@ -42,9 +42,9 @@ def publish(ctx):
|
|||
@task
|
||||
def publish_docker(ctx):
|
||||
with ctx.cd(BASE_DIR):
|
||||
docker_image = "rg.fr-par.scw.cloud/crocmagnon/ynab"
|
||||
docker_image = "crocmagnon/ynab"
|
||||
ctx.run(
|
||||
f"docker build --build-arg OFX_VERSION=$(poetry version -s) -t {docker_image} .",
|
||||
f"docker build --pull --platform linux/amd64 --build-arg OFX_VERSION=$(poetry version -s) -t {docker_image} .",
|
||||
pty=True,
|
||||
echo=True,
|
||||
)
|
||||
|
|
Loading…
Add table
Reference in a new issue