blob: c5f709f05690623b423dcb7d32b7f0585940cc69 (
plain)
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
|
diff --git a/nagstamon.py b/nagstamon.py
index 5d61ef8..0a4db87 100755
--- a/nagstamon.py
+++ b/nagstamon.py
@@ -35,17 +35,17 @@ conf.Convert_Conf_to_Multiple_Servers()
conf.Convert_Conf_to_Custom_Actions()
# try to get resources path if nagstamon got be installed by setup.py
-Resources = ""
-try:
- import pkg_resources
- Resources = pkg_resources.resource_filename("Nagstamon", "resources")
-except Exception, err:
- # get resources directory from current directory - only if not being set before by pkg_resources
- if Resources == "":
- if os.path.exists(os.path.normcase(os.getcwd() + os.sep + "Nagstamon" + os.sep + "resources")):
- Resources = os.path.normcase(os.getcwd() + os.sep + "Nagstamon" + os.sep + "resources")
- else:
- Resources = os.path.normcase(os.getcwd() + os.sep + "resources")
+Resources = "/usr/share/nagstamon/resources"
+#try:
+# import pkg_resources
+# Resources = pkg_resources.resource_filename("Nagstamon", "resources")
+#except Exception, err:
+# # get resources directory from current directory - only if not being set before by pkg_resources
+# if Resources == "":
+# if os.path.exists(os.path.normcase(os.getcwd() + os.sep + "Nagstamon" + os.sep + "resources")):
+# Resources = os.path.normcase(os.getcwd() + os.sep + "Nagstamon" + os.sep + "resources")
+# else:
+# Resources = os.path.normcase(os.getcwd() + os.sep + "resources")
# initialize GUI and actions
# if modules are not available from central python install try the ones in the same directory
|