summary refs log tree commit diff stats
path: root/ranger.py
diff options
context:
space:
mode:
authornfnty <git@nfnty.se>2016-12-23 10:49:25 +0100
committernfnty <git@nfnty.se>2017-01-17 05:59:02 +0100
commite52629c1c70f91ac117e488e04a73bf9e91ab8f9 (patch)
treec92b5de625f7e5dc57ee1374531d14ac60222717 /ranger.py
parent916c239014b95f02bf045f8de0488d7614126edf (diff)
downloadranger-e52629c1c70f91ac117e488e04a73bf9e91ab8f9.tar.gz
linting: Python 2 compat: Import from `__future__`
Diffstat (limited to 'ranger.py')
-rwxr-xr-xranger.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/ranger.py b/ranger.py
index f8c00213..3aa62eec 100755
--- a/ranger.py
+++ b/ranger.py
@@ -20,10 +20,12 @@ if [ "$(cat -- "$tempfile")" != "$(echo -n `pwd`)" ]; then
 fi
 rm -f -- "$tempfile"
 return $returnvalue
-""" and None  # pylint: disable=pointless-statement
+"""
 
-import sys  # NOQA pylint: disable=wrong-import-position
-from os.path import exists, abspath  # NOQA pylint: disable=wrong-import-position
+from __future__ import (absolute_import, print_function)
+
+import sys
+from os.path import exists, abspath
 
 # Need to find out whether or not the flag --clean was used ASAP,
 # because --clean is supposed to disable bytecode compilation
@@ -35,5 +37,5 @@ if __file__[:4] == '/usr' and exists('ranger') and abspath('.') in sys.path:
     sys.path.remove(abspath('.'))
 
 # Start ranger
-import ranger  # NOQA pylint: disable=wrong-import-position,import-self
+import ranger  # NOQA pylint: disable=import-self,wrong-import-position
 sys.exit(ranger.main())  # pylint: disable=no-member