From 559d4862366d74560a8ef2b22f00203e62ba8ce4 Mon Sep 17 00:00:00 2001 From: Olivier Mangin Date: Sat, 8 Jul 2017 00:08:51 -0400 Subject: [PATCH] Fix path not expanded for edit_file command. In particular the issue was preventing notes from being edited. --- pubs/uis.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pubs/uis.py b/pubs/uis.py index d1166f2..20735ad 100644 --- a/pubs/uis.py +++ b/pubs/uis.py @@ -11,7 +11,7 @@ import subprocess from . import color from . import config from .p3 import _get_raw_stdout, _get_raw_stderr, input, ustr -from .content import check_file, read_text_file, write_file +from .content import check_file, read_text_file, write_file, system_path # package-shared ui that can be accessed using : @@ -63,7 +63,7 @@ def _edit_file(editor, path_to_file, temporary=True): write_file(path_to_file, content) else: cmd = editor.split() # this enable editor command with option, e.g. gvim -f - cmd.append(path_to_file) + cmd.append(system_path(path_to_file)) subprocess.call(cmd)