fix(vol): % calc error

This commit is contained in:
ange 2024-04-26 18:10:57 +02:00
parent 1fb88d0ee7
commit 4be53c2809
Signed by: ange
GPG Key ID: 9E0C4157BB7BEB1D
2 changed files with 1 additions and 7 deletions

View File

@ -5,20 +5,14 @@ local servers = {
"pyright",
}
-- Global mappings.
-- See `:help vim.diagnostic.*` for documentation on any of the below functions
vim.keymap.set('n', '<space>e', vim.diagnostic.open_float)
vim.keymap.set('n', '[d', vim.diagnostic.goto_prev)
vim.keymap.set('n', ']d', vim.diagnostic.goto_next)
vim.keymap.set('n', '<space>q', vim.diagnostic.setloclist)
-- Use LspAttach autocommand to only map the following keys
-- after the language server attaches to the current buffer
local on_attach = function(client, bufnr)
vim.bo[ev.buf].omnifunc = 'v:lua.vim.lsp.omnifunc'
-- Buffer local mappings.
-- See `:help vim.lsp.*` for documentation on any of the below functions
local opts = { buffer = ev.buf }
vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, opts)
vim.keymap.set('n', 'gd', vim.lsp.buf.definition, opts)

View File

@ -15,7 +15,7 @@ function update_vol() {
}
read -r _ CUR MUTE < <(wpctl get-volume "$SINK")
CUR="${CUR/#0/}"; CUR="${CUR/#./}"
CUR="$(("10#${CUR/./}"))"
if [ -z "$1" ]; then
echo "$CUR"