from os import listdir,system as ss from datetime import date import time today = date.today() files = listdir() for i in files: tim = today.strftime("%d.%m.%Y_"+time.strftime("%H:%M", time.localtime())) tp = i[i.find('.') + 1:] if tp == "mp3": ss("telegram-upload "+i+" --to https://t.me/streamsradio --caption "+tim) ss("mkdir "+tim) ss("mv "+i+" "+tim+"/")