A lightweight command-line QR code generator that encodes any URL or text into a .png image and renders the QR code directly in your terminal.
- Encodes any URL or plain text into a QR code
- Renders the QR code live in the terminal (ASCII output)
- Saves the output as a
.pngimage to any path you choose - Auto-appends
.pngextension if omitted - Defaults to
generated_qr.pngif no filename is provided
- Python 3.7+
git clone https://github.com/rgsecteam/qr-code-generator
cd qr-code-generatorpython3 -m venv QRCodeGenerator
source QRCodeGenerator/bin/activatepip install -r requirements.txtMake sure your virtual environment is active, then run:
python qr_generator.pyYou will be prompted to enter:
- URL or text — the content to encode
- Output file path — where to save the
.png(press Enter to usegenerated_qr.png)
Example session:
==============================================
RG SECURITY TEAM - QR CODE GENERATOR
==============================================
[+] Enter the URL or Text to encode: https://github.com/rgsecteam
[+] Enter output file path (e.g., /target/path): /home/user/my_qr
[*] Generating QR Code...
[+] Terminal QR Code:
█████████████████████████
█ ▄▄▄▄▄ █▀ █▀▀▀█ ▄▄▄▄▄ █
...
[+] Success! Image saved as: /home/user/my_qr.png
=========================================
qrcode[pil]
The
[pil]extra installsPillow, which is required to save QR codes as image files.
When you're done, deactivate with:
deactivateThis project is open-source and free to use for educational purposes.
Made with 🛡️ by RG Security Team