Merge pull request #25 from cwiki-us-docs/naming_rules

QR 二维码
This commit is contained in:
YuCheng Hu 2021-03-19 00:33:33 -04:00 committed by GitHub
commit 22034b2577
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 15 additions and 0 deletions

15
tests/QRCode.py Normal file
View File

@ -0,0 +1,15 @@
# -*- coding: utf-8 -*-
# Python QR Code Generator
# Author - HoneyMoose(huyuchengus@gmail.com)
# Link Article - https://www.ossez.com/t/python-qr/13396
import qrcode.image.svg
image_path = "resources/token_qr.png"
qr_string = "https://www.ossez.com/c/open-source/python/14"
print(qr_string)
img = qrcode.make(qr_string)
img.save(image_path)