Author: remi
Date: 2009-06-11 12:27:10 +0200 (Thu, 11 Jun 2009)
New Revision: 4778
Modified:
software_suite_v3/smart-core/smart-server/trunk/TDSConfiguration.py
Log:
* Moved location of the dynamic server content on Windows
Modified: software_suite_v3/smart-core/smart-server/trunk/TDSConfiguration.py
===================================================================
--- software_suite_v3/smart-core/smart-server/trunk/TDSConfiguration.py
2009-06-10 12:48:50 UTC (rev 4777)
+++ software_suite_v3/smart-core/smart-server/trunk/TDSConfiguration.py
2009-06-11 10:27:10 UTC (rev 4778)
@@ -76,18 +76,27 @@
TDS_APPLICATION_PATH = localFilePath().getPath()
# Path of the resources
TDS_RESOURCES_PATH = os.path.join(TDS_APPLICATION_PATH, 'resources')
+# All users base dir for Windows
+if os.name == 'nt':
+ ALLUSERSBASEDIR = os.path.join(os.environ['ALLUSERSPROFILE'], "Kysoh",
+ "Tux Droid")
+ if not os.path.isdir(ALLUSERSBASEDIR):
+ os.makedirs(ALLUSERSBASEDIR)
# Path of the resources configurations of the httpserver
if os.name == 'nt':
- TDS_RESOURCES_CONF_PATH = os.path.join(TUXDROID_BASE_PATH,
"configurations", "resources")
+ TDS_RESOURCES_CONF_PATH = os.path.join(ALLUSERSBASEDIR, "configurations",
"resources")
else:
TDS_RESOURCES_CONF_PATH = os.path.join("/etc/tuxdroid", "resources_conf")
# Path of the user configurations
if os.name == 'nt':
- TDS_USERS_CONF_PATH = os.path.join(TUXDROID_BASE_PATH, "configurations",
"users_conf")
+ TDS_USERS_CONF_PATH = os.path.join(ALLUSERSBASEDIR, "configurations",
"users_conf")
else:
TDS_USERS_CONF_PATH = os.path.join("/etc/tuxdroid", "users_conf")
# Path of the default content of the server
-TDS_DEFAULT_CONTENT_PATH = os.path.join(TUXDROID_BASE_PATH, "resources")
+if os.name == 'nt':
+ TDS_DEFAULT_CONTENT_PATH = os.path.join(ALLUSERSBASEDIR, "resources")
+else:
+ TDS_DEFAULT_CONTENT_PATH = os.path.join(TUXDROID_BASE_PATH, "resources")
#
------------------------------------------------------------------------------
# Resources configuration
------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn