@@ -28,6 +28,7 @@ LspProgress.default = {
28
28
spinner_symbols_square = {' ▙ ' , ' ▛ ' , ' ▜ ' , ' ▟ ' },
29
29
spinner_symbols = {' ▙ ' , ' ▛ ' , ' ▜ ' , ' ▟ ' },
30
30
message = { commenced = ' In Progress' , completed = ' Completed' },
31
+ display_lsp_name_after_initialization = false ,
31
32
}
32
33
33
34
-- Initializer
@@ -149,14 +150,16 @@ LspProgress.update_progress = function(self)
149
150
local options = self .options
150
151
local result = {}
151
152
152
-
153
153
for _ , client in pairs (self .clients ) do
154
154
for _ , display_component in pairs (self .options .display_components ) do
155
155
if display_component == ' lsp_client_name' then
156
156
if options .colors .use then
157
- table.insert (result , highlight .component_format_highlight (self .highlights .lsp_client_name ) .. options .separators .lsp_client_name .pre .. client .name .. options .separators .lsp_client_name .post )
157
+ self .lsp_client_name = highlight .component_format_highlight (self .highlights .lsp_client_name ) .. options .separators .lsp_client_name .pre .. client .name .. options .separators .lsp_client_name .post
158
+ table.insert (result , self .lsp_client_name )
158
159
else
159
- table.insert (result , options .separators .lsp_client_name .pre .. client .name .. options .separators .lsp_client_name .post )
160
+ self .lsp_client_name = options .separators .lsp_client_name .pre .. client .name .. options .separators .lsp_client_name .post
161
+ table.insert (result , self .lsp_client_name )
162
+
160
163
end
161
164
end
162
165
if display_component == ' spinner' then
@@ -178,7 +181,11 @@ LspProgress.update_progress = function(self)
178
181
if # result > 0 then
179
182
self .progress_message = table.concat (result , options .separators .component )
180
183
else
181
- self .progress_message = ' '
184
+ if options .display_lsp_name_after_initialization then
185
+ self .progress_message = self .lsp_client_name
186
+ else
187
+ self .progress_message = ' '
188
+ end
182
189
end
183
190
end
184
191
0 commit comments