akinomyoga / ble.sh

Bash Line Editor―a line editor written in pure Bash with syntax highlighting, auto suggestions, vim modes, etc. for Bash interactive sessions.
BSD 3-Clause "New" or "Revised" License
2.33k stars 77 forks source link

If I set all ble-face colors in blerc my terminal takes 5 seconds to let me type #461

Open bennypea opened 3 weeks ago

bennypea commented 3 weeks ago

ble version: Devel 0.4.0-devel3 Bash version: bash-5.2

If I change all of the colors using ble-face and inject those commands in my blerc file my terminal takes at least 5 seconds to let me start typing. Is there anyway around this? I guess all of those commands are processing before I can start typing. All I want to really do is remove the background colors and keep all the foreground colors.

Thanks.

akinomyoga commented 3 weeks ago

I think if you specify all the faces explicitly using ble-face, it would certainly increase the initialization time, but 5 seconds seem unusual.

Q1. Is the 5 seconds all caused by ble-face? What is the initialization time when you comment out the lines of ble-face?

Q2. How many lines of ble-face do you have?

Q3. What are the results of the following commands (after the initialization with 5 seconds)?

$ ble-face | wc -l
$ ble-face -u | wc -l
akinomyoga commented 3 weeks ago

All I want to really do is remove the background colors and keep all the foreground colors.

I'm not sure if I correctly understand what you are trying to do, but why do you need to set all the faces? I think you can omit the settings for the faces that do not have a background color by default. Maybe, it could help if you could provide a more detailed explanation about the situation.

akinomyoga commented 3 days ago

@bennypea ping?