John Lewis have changed their credit card download format yet again. The changes required some additional configurability to be added to mkqif.py
The modifications consist of:
Here's a (fictious) example of a mkqif.cfg file, configuring a Barclay's credit card statement:
; This is a comment [parameters] output_dir=~/QIF source_dir=~/Downloads [barclays] ; type of account - CCard (default) or Bank type=Bank ; Number of header lines to skip in CSV nheaders=2 ; Number of columns expected in CSV ncols=4 ; CSV column containing xcn date date_col=0 ; CSV column containing payee name payee_col=1 ; CSV column containing debit amount debit_col=2 ; CSV column containing credit amount (or flag) credit_col=3 ; debit values are positive (i.e. not QIF-like) debit_is_negative=False ; regexp to select source CSV files file_regexp=barclays.*csv ; format of xcn date (e.g. 05/Jun/2020) date_format=%d/%b/%Y ; regexp to indentify credit is in debit column credit_regexp=PAYMENT.*
Source code for mkqif.py
is now available on Github.