forked from gaugendre/ofx-processor
Compare commits
No commits in common. "master" and "4.0.1" have entirely different histories.
7 changed files with 8 additions and 18 deletions
|
@ -3,7 +3,7 @@ WORKDIR /app
|
||||||
RUN apt-get update && apt-get install -y wget
|
RUN apt-get update && apt-get install -y wget
|
||||||
ARG GECKODRIVER_VERSION="v0.30.0"
|
ARG GECKODRIVER_VERSION="v0.30.0"
|
||||||
ARG GECKODRIVER_FILENAME="geckodriver-$GECKODRIVER_VERSION-linux64"
|
ARG GECKODRIVER_FILENAME="geckodriver-$GECKODRIVER_VERSION-linux64"
|
||||||
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
|
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
|
||||||
|
|
||||||
FROM python:3.10-slim-bullseye as final
|
FROM python:3.10-slim-bullseye as final
|
||||||
RUN apt-get update && apt-get install -y firefox-esr
|
RUN apt-get update && apt-get install -y firefox-esr
|
||||||
|
|
|
@ -53,6 +53,3 @@ git commit
|
||||||
inv tag <version>
|
inv tag <version>
|
||||||
inv publish publish-docker
|
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"
|
"browser.helperApps.neverAsk.saveToDisk", "application/x-ofx"
|
||||||
)
|
)
|
||||||
self.selenium = webdriver.Firefox(options=options)
|
self.selenium = webdriver.Firefox(options=options)
|
||||||
self.selenium.implicitly_wait(30)
|
self.selenium.implicitly_wait(10)
|
||||||
|
|
||||||
def download(self) -> str:
|
def download(self) -> str:
|
||||||
selenium = self.selenium
|
selenium = self.selenium
|
||||||
|
|
|
@ -80,7 +80,7 @@ class LclProcessor(OfxBaseProcessor):
|
||||||
return ofx
|
return ofx
|
||||||
|
|
||||||
|
|
||||||
def main(filename, keep, download, send_method, push_to_ynab):
|
def main(filename, keep, download, send_method):
|
||||||
"""Import LCL bank statement (OFX file)."""
|
"""Import LCL bank statement (OFX file)."""
|
||||||
if download:
|
if download:
|
||||||
if filename:
|
if filename:
|
||||||
|
@ -93,5 +93,4 @@ def main(filename, keep, download, send_method, push_to_ynab):
|
||||||
processor = LclProcessor(filename)
|
processor = LclProcessor(filename)
|
||||||
if send_method:
|
if send_method:
|
||||||
processor.send_reconciled_amount(send_method)
|
processor.send_reconciled_amount(send_method)
|
||||||
if push_to_ynab:
|
processor.push_to_ynab(keep)
|
||||||
processor.push_to_ynab(keep)
|
|
||||||
|
|
|
@ -38,13 +38,6 @@ ARG_TO_OPTION = {
|
||||||
default="",
|
default="",
|
||||||
show_default=True,
|
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,8 +1,9 @@
|
||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "ofx-processor"
|
name = "ofx-processor"
|
||||||
version = "4.1.0"
|
version = "4.0.1"
|
||||||
description = "Personal ofx processor"
|
description = "Personal ofx processor"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
|
license = "Unlicense"
|
||||||
authors = ["Gabriel Augendre <gabriel@augendre.info>"]
|
authors = ["Gabriel Augendre <gabriel@augendre.info>"]
|
||||||
homepage = "https://git.augendre.info/gaugendre/ofx-processor"
|
homepage = "https://git.augendre.info/gaugendre/ofx-processor"
|
||||||
repository = "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
|
@task
|
||||||
def publish_docker(ctx):
|
def publish_docker(ctx):
|
||||||
with ctx.cd(BASE_DIR):
|
with ctx.cd(BASE_DIR):
|
||||||
docker_image = "crocmagnon/ynab"
|
docker_image = "rg.fr-par.scw.cloud/crocmagnon/ynab"
|
||||||
ctx.run(
|
ctx.run(
|
||||||
f"docker build --pull --platform linux/amd64 --build-arg OFX_VERSION=$(poetry version -s) -t {docker_image} .",
|
f"docker build --build-arg OFX_VERSION=$(poetry version -s) -t {docker_image} .",
|
||||||
pty=True,
|
pty=True,
|
||||||
echo=True,
|
echo=True,
|
||||||
)
|
)
|
||||||
|
|
Loading…
Add table
Reference in a new issue