今すぐダウンロードしたファイルのバッチを通じて順にこのファイルを使用してTXTファイルにファイル名保存サンダーのダウンロードファイル名やウェブサイト上で記録ブログ、上の名前変更
コードを:
これは、私の第二のpythonの作品です何も間違っている場合は、あなたがしたい場合は、ソースを示しているあなたに感謝してください、あなたに感謝し、正しい私の悩みを喜ば
# -*- coding: utf-8 -*-
"""
Created on Sat Jun 15 16:28:28 2019
@author: Administrator
"""
#import re
import os
import time
path ='/mtv/'
file = os.listdir(path)
#print(file)
txt = open('add.txt','r')
txt_read = txt.read()
txt_split1 = txt_read.split(',')
for x in range(len(file)):
for y in range(len(txt_split1)-1):
if file[x] in txt_split1[y]:
split_end = txt_split1[y].split('++')
os.rename(path+file[x],path+split_end[0]+'.mp4')
print(file[x],split_end[0])
time.sleep(0.1)