Skip to content

Commit 326df3f

Browse files
committed
Fix python3
1 parent d96333f commit 326df3f

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

cli-count.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
def help():
3434
""" Quick help
3535
"""
36-
print """
36+
print("""
3737
{0} new tag_name (start_value) > default start_value is 0
3838
{0} add tag_name (value) ("a story") > default value is 1
3939
{0} total tag_name (start_date) > date format: dd.mm.yyyy or today
@@ -42,7 +42,7 @@ def help():
4242
{0} delete text (preview) > use preview mode before delete
4343
{0} tags (all) > show tags (with all info)
4444
{0} rename tag_name new_tag_name > rename given tag
45-
""".format(EXECUTABLE_NAME)
45+
""".format(EXECUTABLE_NAME))
4646

4747

4848
def is_valid(tag_name):
@@ -174,10 +174,10 @@ def total(tag_name=None, start_date=None):
174174
if parts[2] == tag_name:
175175
if start_date is not None:
176176
if get_date(parts[0].split("/")[1]) >= start_date:
177-
print nice(line)
177+
print(nice(line))
178178
total += float(parts[3])
179179
else:
180-
print nice(line)
180+
print(nice(line))
181181
total += float(parts[3])
182182

183183
log.info("TOTAL: {}".format(total))
@@ -227,21 +227,21 @@ def list(tag_name=None, start_date=None):
227227
if parts[2] == tag_name:
228228
if start_date is not None:
229229
if get_date(parts[0].split("/")[1]) >= start_date:
230-
print nice(line)
230+
print(nice(line))
231231

232232
else:
233233
with open(FILE, 'r') as f:
234234
lines = f.read().splitlines()
235235
for line in lines:
236236
parts = line.split(" ")
237237
if parts[2] == tag_name:
238-
print nice(line)
238+
print(nice(line))
239239

240240
else:
241241
with open(FILE, 'r') as f:
242242
lines = f.read().splitlines()
243243
for line in lines:
244-
print line
244+
print(line)
245245

246246

247247
def get_tags():
@@ -270,9 +270,9 @@ def tags(option=None):
270270
parts = line.split(" ")
271271
if parts[1] == ACTION_NEW:
272272
if show_all is True:
273-
print line
273+
print(line)
274274
tags.append(parts[2])
275-
print ", ".join(tags)
275+
print(", ".join(tags))
276276

277277

278278
def edit(old_line=None, new_line=None):

0 commit comments

Comments
 (0)