1aba9001ca8827e822017de80b0624d636970b3d — Hugo Osvaldo Barrera 1 year, 6 months ago 7872a36
Properly render keys which contain a dash

When one of the keys (as in key/value) contained a dash, it would not
render properly.

For example, for the entry `access-token!=123 proto=hut`, hiprompt would
render something like:

  access    (empty)
  -         (empty)
  token     (not shown)
  proto     hut

This is due to the dash not being considered a word character and being
split. This patch results in hiprompt rendering the expected prompt:

  access-token    (not shown)
  proto           hut
1 files changed, 1 insertions(+), 0 deletions(-)

M hiprompt_gtk/key.py
M hiprompt_gtk/key.py => hiprompt_gtk/key.py +1 -0
@@ 8,6 8,7 @@ class Key:

        lexer = shlex.shlex(StringIO(key))
        lexer.commenters = ''
        lexer.wordchars += "-"

        while True:
            key = lexer.get_token()