dogtail.config rewrite (slight API change)

Hi folks,

I just committed a rewritten dogtail.config module with a slightly
changed API. Instead of rewriting my (rather large) commit message, I
decided to just forward it to the affected lists. You only need to read
the commit message for dogtail/ (the longest one).

--- Begin Message ---
CVSROOT:	/cvs/gnome
Module name:	dogtail
Changes by:	zcerza	05/10/27 16:51:31

Modified files:
	.              : ChangeLog 
	dogtail        : 
	examples       : 
	examples/data  : sample.cfg 

Log message:
* dogtail/ Rewrite. Rename the Config class to _Config, and provide
a singleton instance named config. It is no longer necessary to instantiate a
_Config instance in any script, whereas previously it was necessary to do so
if any values needed to be changed. Also rename logdir to logDir, scratch to
scratchDir, and data to dataDir. When the *Dir values are changed, the new
directory is created instantly if it does not exist.	NOTE: this is an API
change. Updating any scripts should be as simple as replacing 'Config' with
'config', 'logdir' with 'logDir', 'scratch' with 'scratchDir', 'data' with
'dataDir' and removing any instantiations of the old Config class. Also, the
old way of loading configuration values from a file is no longer supported.
The current preferred method is to create a Python file that contains
something like: "from dogtail.config import config; config.logDir =
'../logs/'; config.debugSearching = True" and then import that file from
whatever scripts need it.

* dogtail/, dogtail/, dogtail/,
examples/, examples/,
examples/, examples/data/sample.cfg: Update
to new config API.

* dogtail/ Update to new config API. Also, change "def
run(application, arguments = None, appName = None):" to "def run(application,
arguments = '', appName = ''):".

* dogtail/ Update to new config API. Also, make run()'s appName
argument default to "''" instead of "None", just like Also, make run() use doDelay() instead of sleep() to
get logging for free via the config.config.debugSearching option.


cvs-commits-list mailing list
cvs-commits-list gnome org

--- End Message ---

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]