add conky
This commit is contained in:
@@ -9,3 +9,5 @@
|
|||||||
defaultBranch = master
|
defaultBranch = master
|
||||||
[pull]
|
[pull]
|
||||||
rebase = false
|
rebase = false
|
||||||
|
[color]
|
||||||
|
ui = auto
|
||||||
|
|||||||
@@ -1,11 +1,20 @@
|
|||||||
window:
|
window:
|
||||||
opacity: 0.7
|
opacity: 0.7
|
||||||
#decorations: none
|
# decorations: none
|
||||||
#dimensions:
|
dimensions:
|
||||||
#lines: 120
|
lines: 115
|
||||||
#columns: 120
|
columns: 257
|
||||||
|
position:
|
||||||
|
x: 1550
|
||||||
|
y: 0
|
||||||
selection:
|
selection:
|
||||||
save_to_clipboard: true
|
save_to_clipboard: true
|
||||||
|
shell:
|
||||||
|
program: /usr/bin/zsh
|
||||||
|
args:
|
||||||
|
- -l
|
||||||
|
- -c
|
||||||
|
- tmux attach || tmux
|
||||||
font:
|
font:
|
||||||
# Normal (roman) font face
|
# Normal (roman) font face
|
||||||
normal:
|
normal:
|
||||||
|
|||||||
82
conky/conky.conf
Normal file
82
conky/conky.conf
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
-- Conky, a system monitor https://github.com/brndnmtthws/conky
|
||||||
|
--
|
||||||
|
-- This configuration file is Lua code. You can write code in here, and it will
|
||||||
|
-- execute when Conky loads. You can use it to generate your own advanced
|
||||||
|
-- configurations.
|
||||||
|
--
|
||||||
|
-- Try this (remove the `--`):
|
||||||
|
--
|
||||||
|
-- print("Loading Conky config")
|
||||||
|
--
|
||||||
|
-- For more on Lua, see:
|
||||||
|
-- https://www.lua.org/pil/contents.html
|
||||||
|
|
||||||
|
conky.config = {
|
||||||
|
alignment = 'top_right',
|
||||||
|
xinerama_head = 1,
|
||||||
|
background = false,
|
||||||
|
border_width = 1,
|
||||||
|
cpu_avg_samples = 2,
|
||||||
|
default_color = 'white',
|
||||||
|
default_outline_color = 'white',
|
||||||
|
default_shade_color = 'white',
|
||||||
|
double_buffer = true,
|
||||||
|
draw_borders = false,
|
||||||
|
draw_graph_borders = true,
|
||||||
|
draw_outline = false,
|
||||||
|
draw_shades = false,
|
||||||
|
extra_newline = false,
|
||||||
|
font = 'FiraCode Nerd Font:size=12',
|
||||||
|
gap_x = 20,
|
||||||
|
gap_y = 20,
|
||||||
|
--gap_x = 3860,
|
||||||
|
--gap_y = 807,
|
||||||
|
minimum_height = 5,
|
||||||
|
minimum_width = 425,
|
||||||
|
net_avg_samples = 2,
|
||||||
|
no_buffers = true,
|
||||||
|
out_to_console = false,
|
||||||
|
out_to_ncurses = false,
|
||||||
|
out_to_stderr = false,
|
||||||
|
out_to_x = true,
|
||||||
|
own_window = true,
|
||||||
|
own_window_class = 'Conky',
|
||||||
|
own_window_type = 'desktop',
|
||||||
|
own_window_transparent = false,
|
||||||
|
own_window_argb_visual = true,
|
||||||
|
own_window_argb_value = 45,
|
||||||
|
show_graph_range = false,
|
||||||
|
show_graph_scale = false,
|
||||||
|
stippled_borders = 0,
|
||||||
|
update_interval = 1,
|
||||||
|
uppercase = false,
|
||||||
|
use_spacer = 'none',
|
||||||
|
use_xft = true,
|
||||||
|
lua_load = '$HOME/.config/conky/lua/cpu.lua',
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
conky.text = [[
|
||||||
|
${color green}System $hr
|
||||||
|
${color grey}OS:$color $sysname
|
||||||
|
${color grey}Host:$color $nodename
|
||||||
|
${color grey}Kernel:$color $kernel
|
||||||
|
${color grey}Arch:$color $machine
|
||||||
|
${color grey}Uptime:$color $uptime
|
||||||
|
${color green}CPU $hr
|
||||||
|
${alignc}${color grey}Total: ${hwmon 0 temp 1}°C | CCD1: ${hwmon 0 temp 3}°C | CCD2: ${hwmon 0 temp 4}°C
|
||||||
|
${color grey}${lua_parse conky_mycpus}
|
||||||
|
${color green}Memory $hr
|
||||||
|
${color grey}RAM Usage:$color $mem/$memmax - $memperc% ${membar 4}
|
||||||
|
${color grey}Swap Usage:$color $swap/$swapmax - $swapperc% ${swapbar 4}
|
||||||
|
${color green}Top $hr
|
||||||
|
${color grey}Processes:$color $processes ${color grey}Threads:$color $threads ${color grey}Running:$color $running_threads
|
||||||
|
${color green}File systems $hr
|
||||||
|
${color grey}/ $color${fs_used /}/${fs_size /} ${fs_bar 6 /}
|
||||||
|
${if_up enp0s31f6}${color green}Networking $hr
|
||||||
|
${color grey}Interface:$color enp0s31f6
|
||||||
|
${color grey}IP:$color ${addr enp0s31f6}
|
||||||
|
${color grey}Up:$color ${upspeed enp0s31f6}
|
||||||
|
${color grey}Down:$color ${downspeed enp0s31f6}${endif}
|
||||||
|
${alignr}${font STIX:size=7}usage:${exec ps -C conky -o pcpu=}%
|
||||||
|
]]
|
||||||
21
conky/lua/cpu.lua
Normal file
21
conky/lua/cpu.lua
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
function conky_mycpus()
|
||||||
|
local file = io.popen("grep -c processor /proc/cpuinfo")
|
||||||
|
local numcpus = file:read("*n")
|
||||||
|
file:close()
|
||||||
|
listcpus = ""
|
||||||
|
for i = 1,numcpus
|
||||||
|
do
|
||||||
|
if (i > 1) then
|
||||||
|
if (i % 2 > 0) then
|
||||||
|
listcpus = listcpus.."\n "
|
||||||
|
end
|
||||||
|
end
|
||||||
|
strI = tostring(i)
|
||||||
|
if i < 10 then
|
||||||
|
strI = " "..strI
|
||||||
|
end
|
||||||
|
listcpus = listcpus.."Core "..strI.." ${color yellow}${freq_g "..strI.."} ${color green}${cpubar cpu"..strI.." 6,75}${color grey} "
|
||||||
|
end
|
||||||
|
|
||||||
|
return listcpus
|
||||||
|
end
|
||||||
4
init.sh
4
init.sh
@@ -33,8 +33,8 @@ ln -s $HOME/.config/nvim/init.vim $HOME/.vimrc
|
|||||||
ln -s $HOME/.config/zsh/.zshrc $HOME/.zshrc
|
ln -s $HOME/.config/zsh/.zshrc $HOME/.zshrc
|
||||||
ln -s $HOME/.config/tmux/tmux.conf $HOME/.tmux.conf
|
ln -s $HOME/.config/tmux/tmux.conf $HOME/.tmux.conf
|
||||||
|
|
||||||
#Install powerline-fonts
|
##Install powerline-fonts
|
||||||
which apt && $PKGINST fonts-powerline || which dnf && $PKGINST powerline-fonts
|
#which apt && $PKGINST fonts-powerline || which dnf && $PKGINST powerline-fonts
|
||||||
|
|
||||||
#Install starship
|
#Install starship
|
||||||
curl -sS https://starship.rs/install.sh | sh
|
curl -sS https://starship.rs/install.sh | sh
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ local on_attach = function(client, bufnr)
|
|||||||
vim.keymap.set('n', '<space>rn', vim.lsp.buf.rename, bufopts)
|
vim.keymap.set('n', '<space>rn', vim.lsp.buf.rename, bufopts)
|
||||||
vim.keymap.set('n', '<space>ca', vim.lsp.buf.code_action, bufopts)
|
vim.keymap.set('n', '<space>ca', vim.lsp.buf.code_action, bufopts)
|
||||||
vim.keymap.set('n', 'gr', vim.lsp.buf.references, bufopts)
|
vim.keymap.set('n', 'gr', vim.lsp.buf.references, bufopts)
|
||||||
vim.keymap.set('n', '<space>f', vim.lsp.buf.formatting, bufopts)
|
vim.keymap.set('n', '<space>f', vim.lsp.buf.format, bufopts)
|
||||||
end
|
end
|
||||||
local capabilities = require('cmp_nvim_lsp').default_capabilities(vim.lsp.protocol.make_client_capabilities())
|
local capabilities = require('cmp_nvim_lsp').default_capabilities(vim.lsp.protocol.make_client_capabilities())
|
||||||
require('lspconfig')['gopls'].setup{
|
require('lspconfig')['gopls'].setup{
|
||||||
@@ -218,6 +218,10 @@ require('lspconfig')['clangd'].setup{
|
|||||||
on_attach = on_attach,
|
on_attach = on_attach,
|
||||||
capabilities = capabilities,
|
capabilities = capabilities,
|
||||||
}
|
}
|
||||||
|
require('lspconfig')['rust_analyzer'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
capabilities = capabilities,
|
||||||
|
}
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
lua <<EOF
|
lua <<EOF
|
||||||
|
|||||||
1
zsh/config.d/.gitignore
vendored
Normal file
1
zsh/config.d/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
local.zsh
|
||||||
Reference in New Issue
Block a user