Advertisement
nerdemma

Generate QR

Jul 28th, 2023
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.44 KB | Source Code | 0 0
  1. #generator of qrcode
  2. #develop by emmanuel breyaue
  3. #more information nerdemma@mastolon.social
  4.  
  5. import qrcode
  6. import datetime
  7. import argparse
  8.  
  9. parser=argparse.ArgumentParser()
  10. parser.add_argument('--qrc',type=str,required=True)
  11. args=parser.parse_args()
  12.  
  13. date=datetime.datetime.now().strftime("%Y-%m-%d-%H-%M-%S")
  14. img = qrcode.make(args)
  15. type(img)
  16.  
  17. print(args.qrc)
  18. img.save(str(date)+".png")
  19.  
  20. #execute
  21.  
  22. #$ ./makeqr.py --qrc $qr_info
Tags: python qr
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement