32 lines
779 B
Python
32 lines
779 B
Python
import os
|
|
|
|
files = [
|
|
'cpp\\miniblink\\test.cpp',
|
|
'cpp\\Views\\DialOfflineDeviceTaskManager.cpp',
|
|
'cpp\\Views\\DialTaskManager.cpp',
|
|
'cpp\\Views\\DialTaskManagerOffline.cpp',
|
|
'cpp\\Views\\DialUploadLoopTask.cpp',
|
|
'h\\StdAfx.h',
|
|
'cpp\\miniblink\\wke.h',
|
|
'h\\WkeWindow\\wke.h'
|
|
]
|
|
|
|
os.chdir(r'd:\gitMe\geomative\GeomativeStudio')
|
|
|
|
for f in files:
|
|
if os.path.exists(f):
|
|
with open(f, 'rb') as file:
|
|
content = file.read()
|
|
|
|
if content.startswith(b'\xef\xbb\xbf'):
|
|
content = content[3:]
|
|
with open(f, 'wb') as file:
|
|
file.write(content)
|
|
print(f'✓ {f}')
|
|
else:
|
|
print(f'○ {f}')
|
|
else:
|
|
print(f'✗ {f} (不存在)')
|
|
|
|
print('\n完成!')
|