Index

dotfiles / 6ac0968

My personal dotfiles for Debian/Ubuntu.

Latest Commit

{#}TimeHashSubjectAuthor#(+)(-)GPG?
802 Feb 2020 15:546ac0968Add passwdgen.py utilityJosh Stockin1150G

Blob @ dotfiles / utils / passwdgen.py

application/x-python421 bytesdownload raw
1#!/usr/bin/env python3.7
2
3import random
4
5def NewPass():
6 random.seed()
7 charactersAllowed = list("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%^&*-=_+ ")
8 random.shuffle(charactersAllowed)
9 passStr = ""
10 for x in range(0,16):
11 passStr += charactersAllowed[random.randint(0,len(charactersAllowed)-1)]
12 return passStr
13
14if __name__ == "__main__":
15 print(f"\"{NewPass()}\"")
16