From a1a8fd89cb46d58f8dcbee85d5cac67bb37265e3 Mon Sep 17 00:00:00 2001 From: bhagwan Date: Sun, 18 Jul 2021 08:51:16 -0700 Subject: [PATCH] ansi colors escape sequence changed to support older lua versions --- lua/fzf-lua/utils.lua | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/lua/fzf-lua/utils.lua b/lua/fzf-lua/utils.lua index 9ba6df7..57160a4 100644 --- a/lua/fzf-lua/utils.lua +++ b/lua/fzf-lua/utils.lua @@ -141,18 +141,21 @@ end M.ansi_codes = {} M.ansi_colors = { - clear = "\x1b[0m", - bold = "\x1b[1m", - black = "\x1b[0;30m", - red = "\x1b[0;31m", - green = "\x1b[0;32m", - yellow = "\x1b[0;33m", - blue = "\x1b[0;34m", - magenta = "\x1b[0;35m", - cyan = "\x1b[0;36m", - grey = "\x1b[0;90m", - dark_grey = "\x1b[0;97m", - white = "\x1b[0;98m", + -- the "\x1b" esc sequence causes issues + -- with older Lua versions + -- clear = "\x1b[0m", + clear = "", + bold = "", + black = "", + red = "", + green = "", + yellow = "", + blue = "", + magenta = "", + cyan = "", + grey = "", + dark_grey = "", + white = "", } for color, escseq in pairs(M.ansi_colors) do