mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-07-09 09:06:12 +02:00
Python 3 improvements
This commit is contained in:
parent
03c1395c01
commit
f9bdc13210
4 changed files with 18 additions and 7 deletions
|
@ -169,7 +169,7 @@ def cli(manual_args=None):
|
|||
# Writing mode
|
||||
if mode_compose:
|
||||
raw = " ".join(args.text).strip()
|
||||
if type(raw) is not unicode:
|
||||
if util.PY2 and type(raw) is not unicode:
|
||||
raw = raw.decode(sys.getfilesystemencoding())
|
||||
entry = journal.new_entry(raw, args.date)
|
||||
entry.starred = args.star
|
||||
|
@ -183,7 +183,7 @@ def cli(manual_args=None):
|
|||
strict=args.strict,
|
||||
short=args.short)
|
||||
journal.limit(args.limit)
|
||||
print(unicode(journal))
|
||||
print(journal.pprint())
|
||||
|
||||
# Various export modes
|
||||
elif args.tags:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue