summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-03-17 02:55:37 +0100
committerhut <hut@lavabit.com>2010-03-17 02:55:37 +0100
commit178dd5ba34590effc53aac43ef7939098b10e399 (patch)
tree9ce518a2c355d6a18237c6c083d80238fadb5537
parent0e2b31644b22395e70a4f431c84c8886aa7106b6 (diff)
downloadranger-178dd5ba34590effc53aac43ef7939098b10e399.tar.gz
removed the need for simple app definitions
at the cost of loosing tab completion for that specific app.
Might add tab completion for such cases later
-rw-r--r--ranger/api/apps.py4
-rw-r--r--ranger/gui/widgets/console.py3
2 files changed, 6 insertions, 1 deletions
diff --git a/ranger/api/apps.py b/ranger/api/apps.py
index eadc0839..e61b5e2c 100644
--- a/ranger/api/apps.py
+++ b/ranger/api/apps.py
@@ -78,6 +78,8 @@ class Applications(FileManagerAware):
 			try:
 				application_handler = getattr(self, 'app_' + app)
 			except AttributeError:
+				if app in self.fm.executables:
+					return tup(app, *context)
 				continue
 			if self._meets_dependencies(application_handler):
 				return application_handler(context)
@@ -99,6 +101,8 @@ class Applications(FileManagerAware):
 		try:
 			handler = getattr(self, 'app_' + app)
 		except AttributeError:
+			if app in self.fm.executables:
+				return tup(app, *context)  # generic app
 			handler = self.app_default
 		return handler(context)
 
diff --git a/ranger/gui/widgets/console.py b/ranger/gui/widgets/console.py
index 20753fbf..f9e4924c 100644
--- a/ranger/gui/widgets/console.py
+++ b/ranger/gui/widgets/console.py
@@ -577,7 +577,8 @@ class QuickOpenConsole(ConsoleWithTab):
 
 
 	def _is_app(self, arg):
-		return self.fm.apps.has(arg)
+		return self.fm.apps.has(arg) or \
+			(not self._is_flags(arg) and arg in self.fm.executables)
 
 	def _is_flags(self, arg):
 		from ranger.core.runner import ALLOWED_FLAGS
Blame the previous revision' href='/akspecs/ranger/blame/Makefile?h=v1.9.3&id=636d93936d26fccdf6fe530568db1b4c41c3f2bf'>^
e06e12ef ^
3a1e1f28 ^
f473be92 ^
3a1e1f28 ^

2c5ea01d ^
5fca2a0b ^
b0a216f5 ^
2c5ea01d ^
b0a216f5 ^



3a1e1f28 ^
b0a216f5 ^
e7758eba ^
b0a216f5 ^

a0077554 ^













88b4d374 ^

a0077554 ^

2c5ea01d ^
582f3519 ^
b06433bc ^
a65a2695 ^

582f3519 ^
94c5d83e ^
dee6cfa6 ^
e9e4b4ff ^
b0a216f5 ^
76612b05 ^
ececd03e ^
b0a216f5 ^
e9e4b4ff ^





612b8b8b ^
e9e4b4ff ^
52403c53 ^
ad51cca4 ^
08e43b29 ^


ad51cca4 ^






b3d031a9 ^
c5f776ed ^
b3d031a9 ^

bc2c5619 ^
c5f776ed ^

b3d031a9 ^

c5f776ed ^

c216901a ^
9d82571b ^

5fca2a0b ^
9cf43c17 ^
5fca2a0b ^
c5f776ed ^

a052151f ^
c5f776ed ^

88b4d374 ^
e416bfe7 ^
88b4d374 ^
e91ae587 ^

5f29f89a ^
e91ae587 ^
f2c8a7ff ^



e416bfe7 ^
185c022e ^
5fca2a0b ^
c7720fff ^

c2d7e36e ^
a6836d5d ^
c2d7e36e ^
c7720fff ^
8d21b83c ^


e9e4b4ff ^
ececd03e ^
e9e4b4ff ^
0c2c782d ^
636d9393 ^
b0a216f5 ^
c6afc196 ^

c0d63e78 ^


ececd03e ^
f2c8a7ff ^

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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150