summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2012-08-15 00:59:24 +0200
committerhut <hut@lavabit.com>2012-08-15 00:59:24 +0200
commit5622e8a811951fca5e48685a1495371920e50bd4 (patch)
tree02959ae1cd84ab3dcf64670071855dc52679e016
parente8b8190d2848dd610c24d4f711326a326a53f065 (diff)
downloadranger-5622e8a811951fca5e48685a1495371920e50bd4.tar.gz
core.runner: renamed flag "d" to "f" in the runner too
-rw-r--r--ranger/config/commands.py4
-rw-r--r--ranger/core/runner.py12
2 files changed, 8 insertions, 8 deletions
diff --git a/ranger/config/commands.py b/ranger/config/commands.py
index 2eff68e6..962b9fd1 100644
--- a/ranger/config/commands.py
+++ b/ranger/config/commands.py
@@ -247,7 +247,7 @@ class open_with(Command):
 		Extracts the application, flags and mode from a string.
 
 		examples:
-		"mplayer d 1" => ("mplayer", "d", 1)
+		"mplayer f 1" => ("mplayer", "f", 1)
 		"aunpack 4" => ("aunpack", "", 4)
 		"p" => ("", "p", 0)
 		"" => None
@@ -458,7 +458,7 @@ class terminal(Command):
 			command = 'x-terminal-emulator'
 		if command not in get_executables():
 			command = 'xterm'
-		self.fm.run(command, flags='d')
+		self.fm.run(command, flags='f')
 
 
 class delete(Command):
diff --git a/ranger/core/runner.py b/ranger/core/runner.py
index c5decf4c..96f557b3 100644
--- a/ranger/core/runner.py
+++ b/ranger/core/runner.py
@@ -14,7 +14,7 @@ run()                             # prints an error message
 
 List of allowed flags:
 s: silent mode. output will be discarded.
-d: detach the process.
+f: fork the process.
 p: redirect output to the pager
 c: run only the current file (not handled here)
 w: wait for enter-press afterwards
@@ -158,13 +158,13 @@ class Runner(object):
 			toggle_ui = False
 			pipe_output = True
 			context.wait = False
-		if 's' in context.flags or 'd' in context.flags:
+		if 's' in context.flags or 'f' in context.flags:
 			devnull_writable = open(os.devnull, 'w')
 			devnull_readable = open(os.devnull, 'r')
 			for key in ('stdout', 'stderr'):
 				popen_kws[key] = devnull_writable
 			popen_kws['stdin'] = devnull_readable
-		if 'd' in context.flags:
+		if 'f' in context.flags:
 			if not isinstance(action, str) and 'setsid' in get_executables():
 				action = ['setsid'] + action
 			toggle_ui = False
@@ -175,11 +175,11 @@ class Runner(object):
 		if 'r' in context.flags:
 			if 'sudo' not in get_executables():
 				return self._log("Can not run with 'r' flag, sudo is not installed!")
-			dflag = ('d' in context.flags)
+			f_flag = ('f' in context.flags)
 			if isinstance(action, str):
-				action = 'sudo ' + (dflag and '-b ' or '') + action
+				action = 'sudo ' + (f_flag and '-b ' or '') + action
 			else:
-				action = ['sudo'] + (dflag and ['-b'] or []) + action
+				action = ['sudo'] + (f_flag and ['-b'] or []) + action
 			toggle_ui = True
 			context.wait = True
 		if 't' in context.flags: