Dirk Meyer wrote: > Environment variables would result in a 3rd way to configure > freevo. Right now we have local_conf.py and freevo.conf. Maybe we can > use the later. The packages need environment variables but the freevo > start script will read freevo.conf and will put some settings in > variables. Maybe we could move more stuff here that most users don't > change:
OK, new proposal: add a file sysconfig.py (better name please). It provides: o reading freevo.conf (in a generic way that it can be changed to a different application). Adding everything found to a dict. This file shouldn't know about the entries freevo expects, except: o handle config variables for locale (or better encoding?), vfs_dir, cache_dir and db_dir. If the variables are nor found, create default values like we discussed. o provide helper functions like 'Unicode' and 'String'. Also some functions to get a cachename (to avoid to much os.path.join in the code to make it look better) and a db name. > Right now it would be LOCALE, OVERLAY_DIR, CACHE_DIR, DB_DIR. Besides > that there is still display (maybe has the real OSD_DISPLAY here), > chanlist and tv_norm. Maybe replace the last two with a COUNTRY > setting. By that we could do more cool stuff. But we need help > here. The COUNTRY setting could be germany and we would know some > basic settings like locale, too. Maybe even Germany/Bremen to know > some frequencies. But if we go that way, we need much help from our > users to get good data. This won't be handled by sysconfig, more from the freevo_setup script. We would have two higher level settings resulting in more settings: display: possible values are the output displays we have now in gui and some higher level, like sdl/mga setting the display to pygame and use mga specific settings. So setting a display in freevo_setup would result in this settings: display (e.g. pygame), subdisplay (e.g. mga, better name please, subdisplay sounds stupid), fb or X, pre/post commands to execute. location: the country settings. Based on pre defined values it will set encoding, tv norm, chanlist, clock layout (12 [ap]m or 24 hour style), xmltv grabber. Comments please! Dischi -- A conclusion is simply the place where you got tired of thinking.
pgpaOD61qW6NH.pgp
Description: PGP signature