Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 15 lines (12 sloc) 528 Bytes
#!/usr/bin/env python
import os
import runpy
PKG = 'mdepub'
try:
run_globals = runpy.run_module(PKG, run_name='__main__', alter_sys=True)
executed = os.path.splitext(os.path.basename(run_globals['__file__']))[0]
if executed != '__main__': # For Python 2.5 compatibility
raise ImportError('Incorrectly executed %s instead of __main__' %
executed)
except ImportError: # For Python 2.6 compatibility
runpy.run_module('%s.__main__' % PKG, run_name='__main__', alter_sys=True)