mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-06-26 10:54:28 +02:00
Use new style formatting
Signed-off-by: Thomas Lauf <thomas.lauf@tngtech.com>
This commit is contained in:
parent
d746b422bf
commit
dc77a8c457
1 changed files with 2 additions and 3 deletions
|
@ -17,11 +17,10 @@ total_active_time = 0
|
|||
|
||||
j = json.loads(doc)
|
||||
for object in j:
|
||||
line = '"%s",' % object['start']
|
||||
line += '"%s"' % (object['end'] if 'end' in object else '')
|
||||
line = '"{}","{}"'.format(object['start'], (object['end'] if 'end' in object else ''))
|
||||
|
||||
if 'tags' in object:
|
||||
for tag in object['tags']:
|
||||
line += ',"%s"' % tag
|
||||
line += ',"{}"'.format(tag)
|
||||
|
||||
print(line)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue