TXT_to_XML.py 328 B

12345678910111213
  1. # %%
  2. basedir = '/home/kora/Desktop/OVI_Data_Local/OVIaspo/DallOVI/datiniXML/'
  3. # %%
  4. import os
  5. # %%
  6. files = os.listdir(basedir)
  7. # %%
  8. for file in files:
  9. if(file.startswith('xmlgat')):
  10. print(file)
  11. print(file.replace('.txt', '.xml'))
  12. os.rename(basedir + file, basedir + file.replace('.txt', '.xml'))
  13. # %%