Skip to content

Commit

Permalink
Make script 2.6 compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilja Bobkevic committed Nov 23, 2015
1 parent 25224de commit fbc0f31
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions data/unbound_ec2_script
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
#!/usr/bin/env python

import sys
import sysconfig

sys.path.append(sysconfig.get_path('purelib'))
if sys.version_info[:2] == (2, 6):
from distutils import sysconfig
sys.path.append(sysconfig.get_python_lib())

import pkg_resources
from unbound_ec2.script import *
else:
import sysconfig
sys.path.append(sysconfig.get_path('purelib'))

__requires__ = 'unbound-ec2'
import pkg_resources

pkg_resources.run_script('unbound-ec2', 'unbound_ec2')
__requires__ = 'unbound-ec2'

pkg_resources.run_script('unbound-ec2', 'unbound_ec2')

0 comments on commit fbc0f31

Please sign in to comment.