This article was last edited over 3 years ago. Information here may no longer be accurate. Please proceed with caution, and feel free to contact me.
zbarimg is a helpful command line tool that can take an image of a QR code and decode the underlying text represented by the code.
This is helpful if you want to decode a Google Authenticator TOTP (Time-based one time password), or any other sort of QR code content.
It should be noted that saving the seed for TOTP codes may open you up to a security vulnerability, but there may be cases when you want this information.
zbarimg can not only decode an image of a QR code,
but a screenshot that contains a QR code. So if you cannot save
the QR code as an image, you can simply take a screenshot and pass
Feel free to try it on this example QR code here.
This QR code should decode to this content.
See also zbarcam.