about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--ranger/__main__.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/ranger/__main__.py b/ranger/__main__.py
index ae3f3221..4da9bb73 100644
--- a/ranger/__main__.py
+++ b/ranger/__main__.py
@@ -48,6 +48,7 @@ def parse_arguments():
 
 	return arg
 
+
 def load_settings(fm):
 	if not ranger.arg.clean:
 		try:
@@ -125,7 +126,6 @@ def main():
 
 	SettingsAware._setup()
 
-	# Initialize objects
 	if arg.targets:
 		target = arg.targets[0]
 		if not os.access(target, os.F_OK):
@@ -142,10 +142,9 @@ def main():
 	else:
 		path = '.'
 
-	EnvironmentAware._assign(Environment(path))
-	SettingsAware._setup_keys()
-
 	try:
+		# Initialize objects
+		EnvironmentAware._assign(Environment(path))
 		fm = FM()
 		load_settings(fm)
 		FileManagerAware._assign(fm)
@@ -162,6 +161,7 @@ def main():
 		except (AttributeError, NameError):
 			pass
 
+
 if __name__ == '__main__':
 	top_dir = os.path.dirname(sys.path[0])
 	sys.path.insert(0, top_dir)