Skip to content

Commit

Permalink
The .qlrc file now supports a ~ in the path. Closes #19
Browse files Browse the repository at this point in the history
  • Loading branch information
Brian Carter committed Nov 28, 2014
1 parent 5b8a621 commit 16269f3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion ql.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,12 @@ def read_config(ledger_file, account, merchant, category, amount):
merchant = config['merc'][merchant]
except:
merchant = merchant

ledger_user = os.path.expanduser(ledger_file)
if os.path.isfile(ledger_file):
datesel(ledger_file, account, merchant, category, amount)
elif os.path.expanduser(ledger_user):
ledger_file = ledger_user
datesel(ledger_file, account, merchant, category, amount)
else:
print("Error! Cannot find %s" % ledger_file)
else:
Expand Down

0 comments on commit 16269f3

Please sign in to comment.