summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--ranger/api/apps.py2
-rw-r--r--ranger/defaults/apps.py25
-rw-r--r--ranger/defaults/keys.py17
-rw-r--r--ranger/defaults/options.py18
4 files changed, 15 insertions, 47 deletions
diff --git a/ranger/api/apps.py b/ranger/api/apps.py
index c01e13a7..7d265aed 100644
--- a/ranger/api/apps.py
+++ b/ranger/api/apps.py
@@ -16,7 +16,7 @@
 This module provides helper functions/classes for ranger.defaults.apps.
 """
 
-import os, sys
+import os, sys, re
 from subprocess import Popen, PIPE
 from ranger.ext.iter_tools import flatten
 from ranger.shared import FileManagerAware
diff --git a/ranger/defaults/apps.py b/ranger/defaults/apps.py
index 23477180..15808c17 100644
--- a/ranger/defaults/apps.py
+++ b/ranger/defaults/apps.py
@@ -1,25 +1,14 @@
-# Copyright (c) 2009, 2010 hut <hut@lavabit.com>
-#
-# Permission to use, copy, modify, and/or distribute this software for any
-# purpose with or without fee is hereby granted, provided that the above
-# copyright notice and this permission notice appear in all copies.
-#
-# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
-# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
-# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
-# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
-# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
-# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-
-import os
-from re import compile, VERBOSE
+"""
+This is the default ranger configuration file for filetype detection
+and application handling.
+"""
+
 from ranger.api.apps import *
 
-INTERPRETED_LANGUAGES = compile(r'''
+INTERPRETED_LANGUAGES = re.compile(r'''
 	^(text|application)\/x-(
 		haskell|perl|python|ruby|sh
-	)$''', VERBOSE)
+	)$''', re.VERBOSE)
 
 class CustomApplications(Applications):
 	def app_default(self, c):
diff --git a/ranger/defaults/keys.py b/ranger/defaults/keys.py
index ca85bc33..24c35648 100644
--- a/ranger/defaults/keys.py
+++ b/ranger/defaults/keys.py
@@ -1,18 +1,5 @@
-# Copyright (c) 2009, 2010 hut <hut@lavabit.com>
-#
-# Permission to use, copy, modify, and/or distribute this software for any
-# purpose with or without fee is hereby granted, provided that the above
-# copyright notice and this permission notice appear in all copies.
-#
-# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
-# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
-# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
-# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
-# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
-# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-
 """
+This is the default key configuration file of ranger.
 Syntax for binding keys: bind(*keys, fnc)
 
 keys are one or more key-combinations which are either:
@@ -22,7 +9,7 @@ keys are one or more key-combinations which are either:
 
 fnc is a function which is called with the CommandArgument object.
 
-The CommandArgument object has these methods:
+The CommandArgument object has these attributes:
 arg.fm: the file manager instance
 arg.wdg: the widget or ui instance
 arg.n: the number typed before the key combination (if allowed)
diff --git a/ranger/defaults/options.py b/ranger/defaults/options.py
index d2df0b05..cb4d90f7 100644
--- a/ranger/defaults/options.py
+++ b/ranger/defaults/options.py
@@ -1,16 +1,8 @@
-# Copyright (c) 2009, 2010 hut <hut@lavabit.com>
-#
-# Permission to use, copy, modify, and/or distribute this software for any
-# purpose with or without fee is hereby granted, provided that the above
-# copyright notice and this permission notice appear in all copies.
-#
-# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
-# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
-# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
-# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
-# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
-# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+"""
+This is the default configuration file of ranger.
+If you do any changes, make sure the import-line stays
+intact and the type of the value stays the same.
+"""
 
 from ranger.api.options import *
 
> 2010-01-01 20:35:22 +0100 committer hut <hut@lavabit.com> 2010-01-01 20:35:22 +0100 notify: merged into statusbar, allow to view the log in the pager' href='/akspecs/ranger/commit/TODO?h=v1.6.0&id=6f43de0af345c63216b03b1e2611abf98266d80a'>6f43de0a ^
fca1fc4f ^
ab65b353 ^

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