Compare commits

..

8 Commits

Author SHA1 Message Date
Guilherme Rugai Freire
7f291a988b
zathura: do not autocopy to clipboard on selection 2026-02-11 01:06:45 -03:00
Guilherme Rugai Freire
f6692c95f3
upadte neovim config 2026-02-11 01:06:19 -03:00
Guilherme Rugai Freire
b84e308a9e
update qtile config 2026-02-11 01:05:01 -03:00
Guilherme Rugai Freire
14a7b63eb2
update global keybindings 2026-02-11 01:04:46 -03:00
Guilherme Rugai Freire
29f0d6b09c
add new stuff to autostart.sh 2026-02-11 01:04:24 -03:00
Guilherme Rugai Freire
49b3d53d40
update picom compositor: only need vsync 2026-02-11 01:03:55 -03:00
Guilherme Rugai Freire
446fd83d16
update cron jobs 2026-02-11 01:02:59 -03:00
Guilherme Rugai Freire
b7405beb76
update ssh config to add hosts 2026-02-11 01:02:40 -03:00
11 changed files with 126 additions and 390 deletions

View File

@ -1,2 +1,2 @@
5 */2 * * * /usr/bin/pacman -Syuw --noconfirm 5 */2 * * * apt-get update
*/30 * * * * /usr/bin/updatedb */30 * * * * /usr/bin/updatedb

View File

@ -1,2 +1,2 @@
*/20 * * * * /usr/bin/newsboat -x reload */5 * * * * XDG_RUNTIME_DIR=/run/user/$(id -u) /home/grfreire/.scripts/bin/check_battery
0 */2 * * * $HOME/.config/code/update-extensions.sh

View File

@ -1,10 +1,11 @@
function SetColor(color) function setTheme(theme)
color = color or "oxocarbon" if theme == 'bamboo' then
vim.cmd.colorscheme(color) require('bamboo').setup({});
require('bamboo').load();
-- Transparent background elseif theme == 'sonokai' then
-- vim.api.nvim_set_hl(0, "Normal", { bg = "none" }) vim.cmd 'colorscheme sonokai';
-- vim.api.nvim_set_hl(0, "NormalFloat", { bg = "none" }) vim.opt.termguicolors = false;
end
end end
SetColor() setTheme('sonokai')

View File

@ -1,75 +1,35 @@
local lsp = require("lsp-zero") require("mason").setup()
require("mason-lspconfig").setup({})
lsp.preset("recommended")
require("mason").setup({})
require("mason-lspconfig").setup({
ensure_installed = {'lua_ls', 'clangd', 'eslint', 'tsserver'},
handlers = { lsp.default_setup }
})
-- Fix Undefined global 'vim'
lsp.configure('lua_ls', {
settings = {
Lua = {
diagnostics = {
globals = { 'vim' }
}
}
}
})
local cmp = require('cmp') local cmp = require('cmp')
local cmp_select = {behavior = cmp.SelectBehavior.Select}
local cmp_mappings = lsp.defaults.cmp_mappings({
['<C-p>'] = cmp.mapping.select_prev_item(cmp_select),
['<C-n>'] = cmp.mapping.select_next_item(cmp_select),
['<CR>'] = cmp.mapping.confirm({ select = true }),
["<C-Space>"] = cmp.mapping.complete(),
})
-- disable completion with tab
-- this helps with copilot setup
cmp_mappings['<Tab>'] = nil
cmp_mappings['<S-Tab>'] = nil
cmp.setup({ cmp.setup({
mapping = cmp_mappings sources = {
{ name = 'nvim_lsp' },
},
snippet = {
expand = function(args)
-- You need Neovim v0.10 to use vim.snippet
vim.snippet.expand(args.body)
end,
},
mapping = cmp.mapping.preset.insert({}),
}) })
lsp.set_preferences({ vim.api.nvim_create_autocmd('LspAttach', {
suggest_lsp_servers = false, desc = 'LSP actions',
sign_icons = { callback = function(event)
error = 'E', local opts = { buffer = event.buf }
warn = 'W',
hint = 'H', vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts)
info = 'I' vim.keymap.set("n", "K", vim.lsp.buf.hover, opts)
} vim.keymap.set("n", "<leader>vws", vim.lsp.buf.workspace_symbol, opts)
}) vim.keymap.set("n", "<leader>vd", vim.diagnostic.open_float, opts)
vim.keymap.set("n", "[d", vim.diagnostic.goto_next, opts)
lsp.on_attach(function(client, bufnr) vim.keymap.set("n", "]d", vim.diagnostic.goto_prev, opts)
local opts = {buffer = bufnr, remap = false} vim.keymap.set("n", "<leader>vca", vim.lsp.buf.code_action, opts)
vim.keymap.set("n", "<leader>vrr", vim.lsp.buf.references, opts)
if client.name == "eslint" then vim.keymap.set("n", "<leader>vrn", vim.lsp.buf.rename, opts)
vim.cmd.LspStop('eslint') vim.keymap.set("i", "<C-h>", vim.lsp.buf.signature_help, opts)
return end,
end
vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts)
vim.keymap.set("n", "K", vim.lsp.buf.hover, opts)
vim.keymap.set("n", "<leader>vws", vim.lsp.buf.workspace_symbol, opts)
vim.keymap.set("n", "<leader>vd", vim.diagnostic.open_float, opts)
vim.keymap.set("n", "[d", vim.diagnostic.goto_next, opts)
vim.keymap.set("n", "]d", vim.diagnostic.goto_prev, opts)
vim.keymap.set("n", "<leader>vca", vim.lsp.buf.code_action, opts)
vim.keymap.set("n", "<leader>vrr", vim.lsp.buf.references, opts)
vim.keymap.set("n", "<leader>vrn", vim.lsp.buf.rename, opts)
vim.keymap.set("i", "<C-h>", vim.lsp.buf.signature_help, opts)
end)
lsp.setup()
vim.diagnostic.config({
virtual_text = true,
}) })

View File

@ -6,64 +6,58 @@
vim.cmd [[packadd packer.nvim]] vim.cmd [[packadd packer.nvim]]
return require('packer').startup(function(use) return require('packer').startup(function(use)
-- Packer package manager itself -- Packer package manager itself
use 'wbthomason/packer.nvim' use 'wbthomason/packer.nvim'
-- Telescope fuzzyfinder -- Telescope fuzzyfinder
use { use {
'nvim-telescope/telescope.nvim', tag = '0.1.5', 'nvim-telescope/telescope.nvim', tag = '0.1.5',
-- or , branch = '0.1.x', -- or , branch = '0.1.x',
requires = { { 'nvim-lua/plenary.nvim' } } requires = { { 'nvim-lua/plenary.nvim' } }
} }
use({ use { 'ribru17/bamboo.nvim' }
"nyoom-engineering/oxocarbon.nvim", use { 'sainnhe/sonokai' }
as = "oxocarbon",
config = function ()
vim.opt.background = "dark"
vim.cmd('colorscheme oxocarbon')
end
})
-- Tree-sitter - AST capabilities for neovim -- Tree-sitter - AST capabilities for neovim
use('nvim-treesitter/nvim-treesitter', { run = ':TSUpdate' }) use('nvim-treesitter/nvim-treesitter', { run = ':TSUpdate' })
use('nvim-treesitter/playground') use('nvim-treesitter/playground')
-- Harpoon - easily go between files -- Harpoon - easily go between files
use('theprimeagen/harpoon') use('theprimeagen/harpoon')
-- Undotree - undo history visualizer -- Undotree - undo history visualizer
use('mbbill/undotree') use('mbbill/undotree')
-- Vim fugitive - git wrapper -- Vim fugitive - git wrapper
use('tpope/vim-fugitive') use('tpope/vim-fugitive')
-- Statusline -- Statusline
use { use {
'nvim-lualine/lualine.nvim', 'nvim-lualine/lualine.nvim',
requires = { 'kyazdani42/nvim-web-devicons', opt = true } requires = { 'kyazdani42/nvim-web-devicons', opt = true }
} }
-- LSP -- LSP
use { use {
'VonHeikemen/lsp-zero.nvim', 'VonHeikemen/lsp-zero.nvim',
requires = { requires = {
-- LSP Support -- LSP Support
{ 'neovim/nvim-lspconfig' }, { 'neovim/nvim-lspconfig' },
{ 'williamboman/mason.nvim' }, { 'williamboman/mason.nvim' },
{ 'williamboman/mason-lspconfig.nvim' }, { 'williamboman/mason-lspconfig.nvim' },
-- Autocompletion -- Autocompletion
{ 'hrsh7th/nvim-cmp' }, { 'hrsh7th/nvim-cmp' },
{ 'hrsh7th/cmp-buffer' }, { 'hrsh7th/cmp-buffer' },
{ 'hrsh7th/cmp-path' }, { 'hrsh7th/cmp-path' },
{ 'saadparwaiz1/cmp_luasnip' }, { 'saadparwaiz1/cmp_luasnip' },
{ 'hrsh7th/cmp-nvim-lsp' }, { 'hrsh7th/cmp-nvim-lsp' },
{ 'hrsh7th/cmp-nvim-lua' }, { 'hrsh7th/cmp-nvim-lua' },
-- Snippets -- Snippets
{ 'L3MON4D3/LuaSnip' }, { 'L3MON4D3/LuaSnip' },
{ 'rafamadriz/friendly-snippets' }, { 'rafamadriz/friendly-snippets' },
} }
} }
end) end)

View File

@ -1,207 +1,11 @@
#################################
# Animations #
#################################
# requires https://github.com/jonaburg/picom
# (These are also the default values)
transition-length = 120
transition-pow-x = 0.1
transition-pow-y = 0.1
transition-pow-w = 0.1
transition-pow-h = 0.1
size-transition = true
#################################
# Corners #
#################################
# requires: https://github.com/sdhand/compton or https://github.com/jonaburg/picom
corner-radius = 8.0;
rounded-corners-exclude = [
"class_g = 'Dunst'",
"! name~=''",
#"window_type = 'normal'",
];
round-borders = 1;
round-borders-exclude = [
];
#################################
# Fading #
#################################
# Fade windows in/out when opening/closing and when opacity changes,
# unless no-fading-openclose is used.
# fading = false
fading = true;
# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
# fade-in-step = 0.028
fade-in-step = 0.3;
# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
# fade-out-step = 0.03
fade-out-step = 0.3;
# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
# fade-delta = 10
# Specify a list of conditions of windows that should not be faded.
# don't need this, we disable fading for all normal windows with wintypes: {}
fade-exclude = [
"class_g = 'slop'", # maim
"! name~=''",
]
# Do not fade on window open/close.
# no-fading-openclose = false
# Do not fade destroyed ARGB windows with WM frame. Workaround of bugs in Openbox, Fluxbox, etc.
# no-fading-destroyed-argb = false
#################################
# Transparency / Opacity #
#################################
# Specify a list of opacity rules, in the format `PERCENT:PATTERN`,
# like `50:name *= "Firefox"`. picom-trans is recommended over this.
# Note we don't make any guarantee about possible conflicts with other
# programs that set '_NET_WM_WINDOW_OPACITY' on frame or client windows.
# example:
# opacity-rule = [ "80:class_g = 'URxvt'" ];
#
# opacity-rule = []
opacity-rule = [
];
#################################
# Background-Blurring #
#################################
blur: {
# requires: https://github.com/ibhagwan/picom
method = "kawase";
strength = 3;
}
# Exclude conditions for background blur.
blur-background-exclude = [
#"window_type = 'dock'",
#"window_type = 'desktop'",
#"class_g = 'URxvt'",
#
# prevents picom from blurring the background
# when taking selection screenshot with `main`
# https://github.com/naelstrof/maim/issues/130
"class_g = 'slop'",
"class_g = 'Gromit-mpx'",
"_GTK_FRAME_EXTENTS@:c",
"! name~=''",
];
#################################
# General Settings #
#################################
experimental-backends = true;
backend = "glx"; backend = "glx";
vsync = true;
# Enable/disable VSync. unredir-if-possible = false;
vsync = true
# Try to detect windows with rounded corners and don't consider them detect-rounded-corners = false;
# shaped windows. The accuracy is not very high, unfortunately.
detect-rounded-corners = true;
# Detect '_NET_WM_OPACITY' on client windows, useful for window managers
# not passing '_NET_WM_OPACITY' of client windows to frame windows.
#
# detect-client-opacity = false
detect-client-opacity = true; detect-client-opacity = true;
# Specify refresh rate of the screen. If not specified or 0, picom will glx-no-stencil = true;
# try detecting this with X RandR extension.
#
# refresh-rate = 60
refresh-rate = 0
# GLX backend: Avoid using stencil buffer, useful if you don't have a stencil buffer.
# Might cause incorrect opacity when rendering transparent content (but never
# practically happened) and may not work with blur-background.
# My tests show a 15% performance boost. Recommended.
#
glx-no-stencil = true
# GLX backend: Avoid rebinding pixmap on window damage.
# Probably could improve performance on rapid window content changes,
# but is known to break things on some drivers (LLVMpipe, xf86-video-intel, etc.).
# Recommended if it works.
#
# glx-no-rebind-pixmap = false
# Set the log level. Possible values are:
# "trace", "debug", "info", "warn", "error"
# in increasing level of importance. Case doesn't matter.
# If using the "TRACE" log level, it's better to log into a file
# using *--log-file*, since it can generate a huge stream of logs.
#
# log-level = "debug"
log-level = "info";
# Set the log file.
# If *--log-file* is never specified, logs will be written to stderr.
# Otherwise, logs will to written to the given file, though some of the early
# logs might still be written to the stderr.
# When setting this option from the config file, it is recommended to use an absolute path.
#
# log-file = '/path/to/your/log/file'
# Show all X errors (for debugging)
# show-all-xerrors = false
# Write process ID to a file.
# write-pid-path = '/path/to/your/log/file'
# Window type settings
#
# 'WINDOW_TYPE' is one of the 15 window types defined in EWMH standard:
# "unknown", "desktop", "dock", "toolbar", "menu", "utility",
# "splash", "dialog", "normal", "dropdown_menu", "popup_menu",
# "tooltip", "notification", "combo", and "dnd".
#
# Following per window-type options are available: ::
#
# fade, shadow:::
# Controls window-type-specific shadow and fade settings.
#
# opacity:::
# Controls default opacity of the window type.
#
# focus:::
# Controls whether the window of this type is to be always considered focused.
# (By default, all window types except "normal" and "dialog" has this on.)
#
# full-shadow:::
# Controls whether shadow is drawn under the parts of the window that you
# normally won't be able to see. Useful when the window has parts of it
# transparent, and you want shadows in those areas.
#
# redir-ignore:::
# Controls whether this type of windows should cause screen to become
# redirected again after been unredirected. If you have unredir-if-possible
# set, and doesn't want certain window to cause unnecessary screen redirection,
# you can set this to `true`.
#
wintypes:
{
normal = { fade = false; shadow = false; }
tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };
dock = { shadow = false; }
dnd = { shadow = false; }
popup_menu = { opacity = 0.95; }
dropdown_menu = { opacity = 0.95; }
};
log-level = "warn";

View File

@ -7,7 +7,7 @@ lxpolkit &
/usr/bin/numlockx /usr/bin/numlockx
# Start compositor # Start compositor
(sleep 1 && picom --experimental-backends) & (sleep 1 && picom) &
# Start notification server # Start notification server
dunst & dunst &
@ -36,6 +36,12 @@ autoxsetwacom
# Run hotkey deamon # Run hotkey deamon
sxhkd & sxhkd &
# Make sure I always have a display active
~/.scripts/bin/display-restore loop &
# Run audio effects
easyeffects --gapplication-service &
# Run xidlehook # Run xidlehook
xidlehook \ xidlehook \
`# Don't lock when there's a fullscreen application` \ `# Don't lock when there's a fullscreen application` \

View File

@ -153,8 +153,8 @@ extension_defaults = widget_defaults.copy()
def generate_bar(left=[], right=[]): def generate_bar(left=[], right=[]):
current_bg_color = colors["background"] bg_color = colors["background"]
current_fg_color = colors["text"] fg_color = colors["text"]
widgets = [] widgets = []
@ -164,23 +164,7 @@ def generate_bar(left=[], right=[]):
padding=0, padding=0,
size_percent=100, size_percent=100,
linewidth=width, linewidth=width,
foreground=current_bg_color, foreground=bg_color,
)
)
def create_arrow(bg=current_bg_color, fg=current_fg_color):
widgets.append(
widget.Sep(
padding=0,
size_percent=100,
linewidth=10,
background=fg,
foreground=bg,
)
)
widgets.append(
widget.TextBox(
text="", background=bg, foreground=fg, padding=-8, fontsize=60
) )
) )
@ -189,39 +173,20 @@ def generate_bar(left=[], right=[]):
for w in left: for w in left:
widgets.append(w) widgets.append(w)
create_sep(4)
is_even = True
is_first_widget = True
for g in right:
if is_even:
current_bg_color = colors["accent_color_dark"]
is_even = False
else:
current_bg_color = colors["accent_color_light"]
is_even = True
if is_first_widget:
create_arrow(colors["background"], colors["accent_color_dark"])
is_first_widget = False
else:
create_arrow(
colors["accent_color_dark"]
if is_even
else colors["accent_color_light"],
colors["accent_color_light"]
if is_even
else colors["accent_color_dark"],
)
for w in g:
w.background = current_bg_color
w.foreground = current_fg_color
widgets.append(w)
create_sep() create_sep()
bg_color = colors["accent_color_dark"]
fg_color = colors["text"]
create_sep(5)
for g in right:
for w in g:
w.background = bg_color
w.foreground = fg_color
widgets.append(w)
create_sep(15)
return widgets return widgets
@ -304,6 +269,7 @@ def main_bar():
text="", text="",
fontsize=22, fontsize=22,
mouse_callbacks={"Button1": lambda: qtile.spawn(POWER_MENU)}, mouse_callbacks={"Button1": lambda: qtile.spawn(POWER_MENU)},
padding=10
), ),
], ],
], ],

View File

@ -9,11 +9,8 @@ super + w
super + f super + f
pcmanfm --no-desktop -n pcmanfm --no-desktop -n
super + b super + o ; {m}
bitwarden-desktop {thunderbird}
super + o ; {m, w, c}
{thunderbird, libreoffice --writer, libreoffice --calc}
super + equal super + equal
boomer boomer
@ -21,9 +18,6 @@ super + equal
super + r super + r
rofi -icon-theme 'Paper' -show-icons -show drun rofi -icon-theme 'Paper' -show-icons -show drun
super + p
~/.scripts/bin/firefox-quick-keywords
super + shift + c super + shift + c
rofi -modi "clipboard:greenclip print" -show clipboard -run-command '{cmd}' rofi -modi "clipboard:greenclip print" -show clipboard -run-command '{cmd}'
@ -33,3 +27,6 @@ super + alt + c
super + shift + e super + shift + e
~/.scripts/bin/clip-moji ~/.scripts/bin/clip-moji
ctrl + alt + t
~/.scripts/bin/restart-touchpad --notify

View File

@ -1,4 +1,4 @@
set selection-clipboard clipboard set selection-clipboard primary
set statusbar-h-padding 0 set statusbar-h-padding 0
set statusbar-v-padding 0 set statusbar-v-padding 0
set page-padding 1 set page-padding 1

View File

@ -1 +1,9 @@
AddKeysToAgent yes AddKeysToAgent yes
Host github.com
IdentityFile ~/.ssh/github
PreferredAuthentications publickey
Host *sr.ht
IdentityFile ~/.ssh/srht
PreferredAuthentications publickey