Put the log in the profile. Release 0.33
This commit is contained in:
parent
031aa6c7d6
commit
7801e05293
@ -1,4 +1,4 @@
|
|||||||
AC_INIT([Sugar],[0.32],[],[sugar])
|
AC_INIT([Sugar],[0.33],[],[sugar])
|
||||||
|
|
||||||
AC_PREREQ([2.59])
|
AC_PREREQ([2.59])
|
||||||
|
|
||||||
|
@ -12,6 +12,8 @@ if dbus.version < (0, 70, 0):
|
|||||||
|
|
||||||
import gobject
|
import gobject
|
||||||
|
|
||||||
|
from sugar import env
|
||||||
|
|
||||||
__queue = None
|
__queue = None
|
||||||
|
|
||||||
CONSOLE_BUS_NAME = 'org.laptop.Sugar.Console'
|
CONSOLE_BUS_NAME = 'org.laptop.Sugar.Console'
|
||||||
@ -121,7 +123,9 @@ def start(console_id, console = None):
|
|||||||
root_logger = logging.getLogger('')
|
root_logger = logging.getLogger('')
|
||||||
root_logger.setLevel(logging.DEBUG)
|
root_logger.setLevel(logging.DEBUG)
|
||||||
root_logger.addHandler(Handler(queue))
|
root_logger.addHandler(Handler(queue))
|
||||||
fileh = logging.FileHandler('/tmp/sugar.log')
|
|
||||||
|
log_file = os.path.join(env.get_profile_path(), 'sugar.log')
|
||||||
|
fileh = logging.FileHandler(log_file)
|
||||||
fileh.setFormatter(logging.Formatter("""[%(asctime)s] %(message)s"""))
|
fileh.setFormatter(logging.Formatter("""[%(asctime)s] %(message)s"""))
|
||||||
root_logger.addHandler(fileh)
|
root_logger.addHandler(fileh)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user