Skip to content

Commit

Permalink
Merge release branch release-1.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
heuer committed Nov 6, 2021
2 parents 8f089c4 + 7fade5e commit ed4a5cc
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 5 deletions.
3 changes: 2 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
Changes
=======

1.4.0 -- 2021-11-dd
1.4.0 -- 2021-11-06
-------------------
* Added option to print QR codes in a more compact manner to the terminal.
Implemented by `Christian Oudard <https://github.com/christian-oudard>`_.
* Minor doc changes
* Added more test cases
* Updated benchmark results


Expand Down
20 changes: 19 additions & 1 deletion man/segno.1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText.
.
.TH "SEGNO" "1" "Mar 23, 2021" "1.3.3" "Segno"
.TH "SEGNO" "1" "Nov 06, 2021" "1.4.0" "Segno"
.SH NAME
segno \- Segno QR Code encoder
.
Expand Down Expand Up @@ -131,6 +131,12 @@ images. Some output formats, i.e. SVG, accept a decimal value.
Output file.
If not specified, the QR Code is printed to the terminal
.UNINDENT
.INDENT 0.0
.TP
.B \-\-compact
Indicates that the QR code should be printed to the terminal in a more
compact manner.
.UNINDENT
.SS Module Colors
.sp
Arguments to specify the module colors. Multiple colors are supported for
Expand Down Expand Up @@ -344,6 +350,18 @@ Prints a 2\-Q QR code to the terminal
.sp
.nf
.ft C
$ segno \-\-compact "I am the walrus"
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
Prints a 1\-L QR code to the terminal in a more compact manner
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
$ segno \-o=yesterday.png "Yesterday"
.ft P
.fi
Expand Down
2 changes: 1 addition & 1 deletion segno/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
except NameError: # pragma: no cover
str_type = str

__version__ = '1.3.4.dev'
__version__ = '1.4.0'

__all__ = ('make', 'make_qr', 'make_micro', 'make_sequence', 'QRCode',
'QRCodeSequence', 'DataOverflowError')
Expand Down
2 changes: 1 addition & 1 deletion segno/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ def _convert_scale(val):
type=int)
# Terminal
terminal_group = parser.add_argument_group('Terminal', 'Terminal specific options')
terminal_group.add_argument('--compact', help='Indicates that the QR code should be printed in a more compact manner',
terminal_group.add_argument('--compact', help='Indicates that the QR code should be printed in a more compact manner', # noqa: E501
action='store_true')
# Show Segno's version --version and -v are taken by QR Code version
parser.add_mutually_exclusive_group().add_argument('--ver', '-V', help="Shows Segno's version",
Expand Down
2 changes: 1 addition & 1 deletion tests/test_covid_cert.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def test_covid_cert():
"QNC2BFUF$SU%BO*N5PIBPIAOI-+R2YBV44PZB6H0CJ0QCK0YQK*R3T3+7A.N88J4R$F/MAITH6QS03L0QIRR97I2HOAXL92L0. KOK" \
"GTM8$M8SNCT64RR7+V4YC5/HQRPOHCR6W9.DPEA7IB65C94JB+ONS.CUIA7LE9JAF+B**O3-SY$NRUEG1AK/4C6DM.SY$NWYMG3GUB" \
"RCEIFRMLNKNM8POCJPG8/0NOLZGIZCUOY55*LTUJS1D7.J9$7$.IWQOMJV$6M53AA:6Z2S./BXPHRKGJUHB1WN5LH/M0:3P+E$$BWW" \
"NB8V5ZRF9JMKAX AAOL3H02YF*OF"
"NB8V5ZRF9JMKAX AAOL3H02YF*OF" # noqa: E501
# Don't use another error correction mode than "M", not sure if this is a requirement, though
qr = segno.make(cert_raw, error='m', boost_error=False)
assert 'M' == qr.error
Expand Down

0 comments on commit ed4a5cc

Please sign in to comment.