PageRenderTime 15ms CodeModel.GetById 9ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/scripts/paster.py

https://bitbucket.org/cistrome/cistrome-harvard/
Python | 33 lines | 19 code | 0 blank | 14 comment | 0 complexity | 2f837729792ce82ac63d35f6247a5bbf MD5 | raw file
 1"""
 2Bootstrap the Galaxy framework.
 3
 4This should not be called directly!  Use the run.sh script in Galaxy's
 5top level directly.
 6"""
 7
 8import os, sys
 9
10# ensure supported version
11from check_python import check_python
12try:
13    check_python()
14except:
15    sys.exit( 1 )
16
17new_path = [ os.path.join( os.getcwd(), "lib" ) ]
18new_path.extend( sys.path[1:] ) # remove scripts/ from the path
19sys.path = new_path
20
21from galaxy import eggs
22import pkg_resources
23
24if 'LOG_TEMPFILES' in os.environ:
25    from log_tempfile import TempFile
26    _log_tempfile = TempFile()
27    import tempfile
28
29pkg_resources.require( "Paste" )
30pkg_resources.require( "PasteDeploy" )
31
32from galaxy.util.pastescript import serve
33serve.run()