fix path not changes

This commit is contained in:
Minoplhy 2021-11-05 22:03:04 +07:00 committed by GitHub
parent b1b36ff6b3
commit 1f349a5cb7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,11 +3,11 @@ import glob
import shutil
def filepath_mass_changer(Version ,path ,apapath, extension="txt"):
f = glob.glob(os.path.join(path,"*.txt"))
f = glob.glob(os.path.join(path,"*."+extension))
for filename in f:
s = os.path.basename(filename)
os.rename(filename, os.path.join(path, Version + '_' + s ))
f = glob.glob(os.path.join(path,"*."+extension))
for filename in f:
s = os.path.basename(filename)
shutil.copy2(os.path.join(path,s), apapath)
shutil.copy2(os.path.join(path,s), apapath)