diff options
author | Daniel Narvaez <dwnarvaez@gmail.com> | 2012-12-10 16:53:17 (GMT) |
---|---|---|
committer | Daniel Narvaez <dwnarvaez@gmail.com> | 2012-12-14 10:27:48 (GMT) |
commit | a65ee61008b4d5e65d9587fa86c0ae707e07a8f8 (patch) | |
tree | 1121bcea5d1d74b6eeeeb99dc492642cf1a908c7 | |
parent | a1b444012995b3e5183c0970ec03678792b49b44 (diff) |
Factor out cleanup_temporary files
To simplify a bit main
-rwxr-xr-x | src/jarabe/main.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/jarabe/main.py b/src/jarabe/main.py index 55d0496..a2444e0 100755 --- a/src/jarabe/main.py +++ b/src/jarabe/main.py @@ -173,7 +173,7 @@ def start_home(): def intro_window_done_cb(window): start_home() -def main(): +def cleanup_temporary_files(): try: from sugar3 import env # Remove temporary files. See http://bugs.sugarlabs.org/ticket/1876 @@ -185,6 +185,9 @@ def main(): # sugar from starting if (for example) the disk is full or read-only. print 'temporary files cleanup failed: %s' % e +def main(): + cleanup_temporary_files() + from sugar3 import logger # NOTE: This needs to happen so early because some modules register translatable # strings in the module scope. |