Compare commits
3 Commits
7fe2da7d37
...
519eecbc4b
Author | SHA1 | Date | |
---|---|---|---|
519eecbc4b | |||
72d94850b4 | |||
|
1bd3ea5adc |
@ -8,7 +8,7 @@ local M = {} -- The module to export
|
||||
M = {
|
||||
-- misc
|
||||
sign_error = "",
|
||||
sign_warning = "",
|
||||
sign_warn = "",
|
||||
sign_hint = "",
|
||||
sign_info = "",
|
||||
}
|
||||
|
@ -102,10 +102,10 @@ end
|
||||
local function get_lsp_diagnostics()
|
||||
local result = {}
|
||||
local levels = {
|
||||
errors = "Error",
|
||||
warnings = "Warn",
|
||||
error = "Error",
|
||||
warn = "Warn",
|
||||
info = "Info",
|
||||
hints = "Hint"
|
||||
hint = "Hint"
|
||||
}
|
||||
|
||||
for k, level in pairs(levels) do
|
||||
@ -152,12 +152,12 @@ local left = table.concat {
|
||||
{
|
||||
process_diagnostics(
|
||||
globals.sign_error .. " ",
|
||||
diagnostics.errors,
|
||||
diagnostics.error,
|
||||
"%#DiagnosticVirtualTextError#"
|
||||
),
|
||||
process_diagnostics(
|
||||
globals.sign_warning .. " ",
|
||||
diagnostics.warnings,
|
||||
globals.sign_warn .. " ",
|
||||
diagnostics.warn,
|
||||
"%#DiagnosticVirtualTextWarn#"
|
||||
),
|
||||
process_diagnostics(
|
||||
|
@ -42,6 +42,9 @@ do
|
||||
if [ "Full" = "$status" ]; then
|
||||
status=" " && capacity="FULL"
|
||||
printf " %s:%s(%s) " "$slot" "$status" "$capacity"
|
||||
else
|
||||
if [ 100 -lt $(expr $capacity) ]; then
|
||||
status=""
|
||||
else
|
||||
if [ "$status" = "Charging" ]; then
|
||||
status=""
|
||||
@ -57,4 +60,5 @@ do
|
||||
fi
|
||||
printf " %s:%s (%0.2d%%) " "$slot" "$status" "$capacity";
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
Reference in New Issue
Block a user