change example

This commit is contained in:
quackerd 2021-02-19 18:31:05 -05:00
parent ead4a92517
commit da45cf4f5a
Signed by: d
GPG Key ID: F73412644EDE357A

View File

@ -35,7 +35,7 @@ def main():
subprocess.check_call(shlex.join(["addgroup", elements[0], elements[3]]), shell=True) subprocess.check_call(shlex.join(["addgroup", elements[0], elements[3]]), shell=True)
print("Added user " + elements[0] + " to group " + elements[3]) print("Added user " + elements[0] + " to group " + elements[3])
# set passwd # set passwd
subprocess.check_call(shlex.join(["echo", "-ne", "\"" + elements[2] + "\n" + elements[2] + "\n\""]) + " | " + shlex.join(["smbpasswd", "-a", "-U", elements[0]])), shell=True) subprocess.check_call(shlex.join(["echo", "-ne", "\"" + elements[2] + "\n" + elements[2] + "\n\""]) + " | " + shlex.join(["smbpasswd", "-a", "-U", elements[0]]), shell=True)
print("Set user " + elements[0] + " password to " + elements[2]) print("Set user " + elements[0] + " password to " + elements[2])
main() main()