Fix iex prompt in recent erlang versions

This commit is contained in:
Daniel Flanagan 2023-10-30 20:41:09 -05:00
parent 5b73c62d2d
commit e685cd5624
Signed by: lytedev
GPG key ID: 5B2020A0F9921EF4

View file

@ -14,23 +14,22 @@
limit: :infinity, limit: :infinity,
charlists: :as_lists charlists: :as_lists
], ],
default_prompt: default_prompt: [
[ # ANSI CHA, move cursor to column 1
# ANSI CHA, move cursor to column 1 # "\e[G",
"\e[G", :magenta,
:magenta, # IEx prompt variable
# IEx prompt variable "%prefix",
"%prefix", "#",
"#", # IEx prompt variable
# IEx prompt variable "%counter",
"%counter", # plain string
# plain string ">",
">", :reset
:reset
] ]
|> IO.ANSI.format() |> IO.ANSI.format()
|> IO.chardata_to_string() |> IO.chardata_to_string()
) )
''; '';
}; };
} }