From 37c4f2d98d4f2ec33e4d2935d34b862cd7923aeb Mon Sep 17 00:00:00 2001 From: ornicar Date: Sun, 13 Feb 2011 12:08:05 -0800 Subject: [vim integration] the temp file is now passed through RANGER_RETURN_FILE --- ranger/defaults/apps.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ranger/defaults/apps.py b/ranger/defaults/apps.py index 1585012b..44f0684a 100644 --- a/ranger/defaults/apps.py +++ b/ranger/defaults/apps.py @@ -55,9 +55,9 @@ class CustomApplications(Applications): """How to determine the default application?""" f = c.file - if 'INVIM' in os.environ: - tmp_file = gettempdir() + "/ranger-selected-file" - with open(tmp_file, 'w') as tmp: + return_file = os.getenv("RANGER_RETURN_FILE") + if return_file is not None: + with open(return_file, 'w') as tmp: tmp.write(f.path) raise SystemExit() -- cgit 1.4.1-2-gfad0