~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/osutils.py

default .bazaar, .bzr.log and .bazaar/bazaar.conf retain
the ownershup of the containing directory.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1590
1590
            real_handlers[kind](abspath, relpath)
1591
1591
 
1592
1592
 
 
1593
def copy_ownership(src, dst):
 
1594
    """copy user and group ownership from src file/dir to dst file/dir"""
 
1595
    if os.name == 'posix':
 
1596
        s = os.stat(src)
 
1597
        os.chown(dst, s.st_uid, s.st_gid)
 
1598
        return True
 
1599
    return False
 
1600
 
 
1601
 
1593
1602
def path_prefix_key(path):
1594
1603
    """Generate a prefix-order path key for path.
1595
1604