[Spambayes-checkins] spambayes/windows/py2exe setup_all.py, 1.21,
1.22
Tony Meyer
anadelonbrin at users.sourceforge.net
Thu Apr 7 04:19:51 CEST 2005
Update of /cvsroot/spambayes/spambayes/windows/py2exe
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5524/windows/py2exe
Modified Files:
setup_all.py
Log Message:
Install language files. At the moment these are just considered data files - a better
system could definitely be designed.
(Maybe the languages directory should be in the spambayes package, so importing is
easy?)
Index: setup_all.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/windows/py2exe/setup_all.py,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -d -r1.21 -r1.22
*** setup_all.py 7 Apr 2005 01:31:22 -0000 1.21
--- setup_all.py 7 Apr 2005 02:19:48 -0000 1.22
***************
*** 89,93 ****
],
)
-
service = dict(
dest_base = "bin/sb_service",
--- 89,92 ----
***************
*** 140,143 ****
--- 139,157 ----
]
+ language_files = []
+ languages_root = os.path.join(sb_top_dir, "languages")
+ def add_language_files(current_dir):
+ files = os.listdir(current_dir)
+ for fn in files:
+ full_fn = os.path.join(current_dir, fn)
+ if os.path.isdir(full_fn):
+ add_language_files(full_fn)
+ continue
+ if os.path.splitext(fn)[1] == ".py":
+ dest_name = os.path.join("languages", "%s" %
+ (full_fn[len(languages_root)+1:],))
+ language_files.append([os.path.dirname(dest_name), [full_fn]])
+ add_language_files(languages_root)
+
common_data_files = [
["", [os.path.join(sb_top_dir, r"windows\resources\sbicon.ico")]],
***************
*** 164,168 ****
windows=[pop3proxy_tray, outlook_addin_register, autoconfigure],
# and the misc data files
! data_files = outlook_data_files + proxy_data_files + common_data_files,
options = {"py2exe" : py2exe_options},
zipfile = "lib/spambayes.modules",
--- 178,183 ----
windows=[pop3proxy_tray, outlook_addin_register, autoconfigure],
# and the misc data files
! data_files = outlook_data_files + proxy_data_files + \
! common_data_files + language_files,
options = {"py2exe" : py2exe_options},
zipfile = "lib/spambayes.modules",
More information about the Spambayes-checkins
mailing list