Merge pull request #2 from Entwicklerpages/master
Update extractunitypackage.py
This commit is contained in:
commit
5ae356791a
|
@ -16,6 +16,7 @@
|
||||||
# specified, the path should already exist.
|
# specified, the path should already exist.
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
import stat
|
||||||
import shutil
|
import shutil
|
||||||
import sys
|
import sys
|
||||||
import tarfile
|
import tarfile
|
||||||
|
@ -91,7 +92,12 @@ for asset in mapping:
|
||||||
os.makedirs(destDir)
|
os.makedirs(destDir)
|
||||||
|
|
||||||
shutil.move(source, destFile)
|
shutil.move(source, destFile)
|
||||||
|
|
||||||
|
# change file permissions for unix because under mac os x
|
||||||
|
# (perhaps also other unix systems) all files are marked as executable
|
||||||
|
# for safety reasons os x prevent the access to the extracted files
|
||||||
|
os.chmod(destFile, stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP | stat.S_IROTH)
|
||||||
|
|
||||||
print asset, '=>', mapping[asset]
|
print asset, '=>', mapping[asset]
|
||||||
|
|
||||||
# done, cleanup any leftovers...
|
# done, cleanup any leftovers...
|
||||||
|
|
Loading…
Reference in a new issue