Merge branch 'tweaks' of git://github.com/Code0x58/colout into develop

This commit is contained in:
Johann Dreo 2018-08-03 15:30:15 +02:00
commit cb790b3089
2 changed files with 4 additions and 2 deletions

View file

@ -31,6 +31,8 @@ signal.signal( signal.SIGPIPE, signal.SIG_DFL )
# Global variable(s)
###############################################################################
PY2 = sys.version_info.major == 2
context = {}
debug = False
@ -753,7 +755,7 @@ def write(colored, stream = sys.stdout):
"""
Write "colored" on sys.stdout, then flush.
"""
if six.PY2: # If Python 2.x: force unicode
if PY2: # If Python 2.x: force unicode
if isinstance(colored, unicode):
colored = colored.encode('utf-8')
try:

View file

@ -14,7 +14,7 @@ if sys.argv[-1] == 'publish':
packages = ['colout']
requires = ['argparse', 'pygments', 'babel']
requires = ['argparse; python_version < "2.7"', 'pygments', 'babel']
setup(
name='colout',