File: __init__.py

package info (click to toggle)
python-docutils 0.7-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 6,732 kB
  • ctags: 4,443
  • sloc: python: 36,034; lisp: 3,402; sh: 111; makefile: 106
file content (14 lines) | stat: -rw-r--r-- 306 bytes parent folder | download | duplicates (59)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import os
import os.path
import sys

sys.path.insert(0, os.path.abspath(os.path.dirname(__file__)))
prev = ''
while sys.path[0] != prev:
    try:
        import DocutilsTestSupport
        break
    except ImportError:
        prev = sys.path[0]
        sys.path[0] = os.path.dirname(prev)
sys.path.pop(0)