~hopem/charms/trusty/cinder/ensure-apache-restart

« back to all changes in this revision

Viewing changes to hooks/charmhelpers/fetch/bzrurl.py

  • Committer: Liam Young
  • Date: 2015-01-09 16:02:39 UTC
  • mfrom: (65 cinder.next)
  • mto: This revision was merged to the branch mainline in revision 67.
  • Revision ID: liam.young@canonical.com-20150109160239-qldk423wxfno2ao3
Merged next in and resolved conflicts

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
)
6
6
from charmhelpers.core.host import mkdir
7
7
 
 
8
import six
 
9
if six.PY3:
 
10
    raise ImportError('bzrlib does not support Python3')
 
11
 
8
12
try:
9
13
    from bzrlib.branch import Branch
10
14
except ImportError:
42
46
        dest_dir = os.path.join(os.environ.get('CHARM_DIR'), "fetched",
43
47
                                branch_name)
44
48
        if not os.path.exists(dest_dir):
45
 
            mkdir(dest_dir, perms=0755)
 
49
            mkdir(dest_dir, perms=0o755)
46
50
        try:
47
51
            self.branch(source, dest_dir)
48
52
        except OSError as e: