about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--ranger/core/actions.py11
1 files changed, 7 insertions, 4 deletions
diff --git a/ranger/core/actions.py b/ranger/core/actions.py
index f8364250..86927a6e 100644
--- a/ranger/core/actions.py
+++ b/ranger/core/actions.py
@@ -490,10 +490,13 @@ class Actions(  # pylint: disable=too-many-instance-attributes,too-many-public-m
                 mode = narg
             tfile = self.thisfile
             selection = self.thistab.get_selection()
-            if not self.thistab.enter_dir(tfile) and selection:
-                result = self.execute_file(selection, mode=mode)
-                if result in (False, ASK_COMMAND):
-                    self.open_console('open_with ')
+            if selection:
+                if selection.is_directory:
+                    self.thistab.enter_dir(tfile)
+                else:
+                    result = self.execute_file(selection, mode=mode)
+                    if result in (False, ASK_COMMAND):
+                        self.open_console('open_with ')
         elif direction.vertical() and cwd.files:
             pos_new = direction.move(
                 direction=direction.down(),
eam.mu?h=hlt&id=bae22d720f6a6f3922c29cd7dc4218c7564bbed9'>bae22d72 ^
30012350 ^



5c058ad6 ^


bae22d72 ^


30012350 ^



1694f9a3 ^

30012350 ^




34ac52cb ^
30012350 ^






bae22d72 ^
492fb278 ^






















1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69