Skip to content

Commit

Permalink
Implemented automatic transaction notification.
Browse files Browse the repository at this point in the history
  • Loading branch information
etienne committed Feb 4, 2021
1 parent cf3239b commit 956b43e
Show file tree
Hide file tree
Showing 4 changed files with 645 additions and 119 deletions.
2 changes: 1 addition & 1 deletion AlignAmount.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def run(self, edit):

# Set match pattern.
p = re.compile(
r'^\s+([\[\]\w:\s_-]+)\s+([-$£¥€¢\d,_]+)(.?[\d]*.*)$')
r'^\s+([\[\]\w:\s_-]+)\s+([-$£¥€¢\d,_]+)(?:.\d*)?.*$')

for line in reversed(lines):

Expand Down
6 changes: 3 additions & 3 deletions SearchAccountPayee.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,15 @@ def get_info(filename, search_key):
list
List of key entries.
"""
if isinstance(search_key, str):
search_key = [search_key]
# if isinstance(search_key, str):
# search_key = [search_key]

with open(filename) as file:
content = file.read()

result = re.findall(r'^{} (.+)$'.format(search_key), content, re.M)

return map(str.strip, result)
return list(map(str.strip, result))


class LedgerBaseSearchCommand(sublime_plugin.TextCommand):
Expand Down
Loading

0 comments on commit 956b43e

Please sign in to comment.