awtk/3rd/SDL/sync.py
2018-10-16 09:44:41 +08:00

25 lines
496 B
Python
Executable File

#!/usr/bin/python
import os
import glob
import copy
import shutil
import platform
def joinPath(root, subdir):
return os.path.normpath(os.path.join(root, subdir))
# XXX: make sure no no ascii chars in the path name.
SRC_ROOT_DIR=joinPath(os.getcwd(), '../../../3rd/SDL/');
DST_ROOT_DIR=os.getcwd();
def copyFiles(src):
s = joinPath(SRC_ROOT_DIR, src)
d = joinPath(DST_ROOT_DIR, src)
print(s + '->' + d)
shutil.rmtree(d, True)
shutil.copytree(s, d)
copyFiles('src');