home *** CD-ROM | disk | FTP | other *** search
/ MacAddict 108 / MacAddict108.iso / Software / Internet & Communication / JunkMatcher 1.5.5.dmg / JunkMatcher.app / Contents / Resources / Engine / consts.pyc (.txt) < prev    next >
Encoding:
Python Compiled Bytecode  |  2005-06-01  |  2.1 KB  |  46 lines

  1. # Source Generated with Decompyle++
  2. # File: in.pyc (Python 2.3)
  3.  
  4. import sys
  5. import os
  6. import os.path as os
  7. import shutil
  8. import re
  9. ROOT_PATH = '%s/' % os.path.split(os.path.split(os.path.abspath(__file__))[0])[0]
  10. DEFAULTS_PATH = '%s/Defaults/' % ROOT_PATH
  11. ENGINE_PATH = '%s/Engine/' % ROOT_PATH
  12. BIN_PATH = '%s/bin/' % ROOT_PATH
  13. HOMELIB_PATH = os.path.expanduser('~/Library/')
  14. CONF_PATH = '%sApplication Support/JunkMatcher/' % HOMELIB_PATH
  15. TMP_PATH = '%stemp/' % CONF_PATH
  16. if os.path.exists(CONF_PATH):
  17.     for f in os.listdir(DEFAULTS_PATH):
  18.         if not os.path.exists('%s%s' % (CONF_PATH, f)):
  19.             shutil.copy2('%s%s' % (DEFAULTS_PATH, f), '%s%s' % (CONF_PATH, f))
  20.             continue
  21.     
  22. else:
  23.     shutil.copytree(DEFAULTS_PATH, CONF_PATH)
  24. if not os.path.exists(TMP_PATH):
  25.     os.makedirs(TMP_PATH)
  26.  
  27. pythonSitePath = '%slib/python2.3/site-packages' % ROOT_PATH
  28. sys.path[0:0] = [
  29.     ENGINE_PATH,
  30.     pythonSitePath,
  31.     '%s/PyObjC' % pythonSitePath,
  32.     '%s/PyObjC/Foundation' % pythonSitePath]
  33. httpPat = re.compile('(?i)https?:/?/?[^"\\\'<> \\t\\n\\r\\f\\v]+')
  34. mpPat = re.compile('\\(\\?#[^)]+\\)')
  35. JM_ENGINE_VER = '1.5.5'
  36. DEFAULT_FILE_ENCODING = 'utf8'
  37. DEFAULT_MX_TIMEOUT = 10
  38. SAFE_SITE_SIZE_RATIO = 0.97999999999999998
  39.  
  40. class JMExceptionMetaPattern(Exception):
  41.     
  42.     def __init__(self, info):
  43.         self.info = info
  44.  
  45.  
  46.