summary refs log tree commit diff stats
path: root/ranger
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-09-27 02:38:20 +0200
committerhut <hut@lavabit.com>2010-09-27 02:38:20 +0200
commit4d9266ac1fa9f163ce7a9738f07f380ba7e70e45 (patch)
treea2aa01f2e643ac913b77edf144d9abce2204d0f6 /ranger
parent4e0ca535b1f44741b9291ba5f6a729c8cfeddda0 (diff)
downloadranger-4d9266ac1fa9f163ce7a9738f07f380ba7e70e45.tar.gz
defaults.apps: open empty files with unknown mimetype in vim
Diffstat (limited to 'ranger')
-rw-r--r--ranger/defaults/apps.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ranger/defaults/apps.py b/ranger/defaults/apps.py
index 8f7ddb5e..85abb2dc 100644
--- a/ranger/defaults/apps.py
+++ b/ranger/defaults/apps.py
@@ -87,7 +87,7 @@ class CustomApplications(Applications):
 		if f.image:
 			return self.either(c, 'feh', 'eog', 'mirage')
 
-		if f.document or f.filetype.startswith('text'):
+		if f.document or f.filetype.startswith('text') or f.size == 0:
 			return self.either(c, 'editor')
 
 		# You can put this at the top of the function and mimeopen will