Merge branch 'main' of ssh://git.olympuslab.net:522/tiago/dotfiles

This commit is contained in:
Tiago Sousa 2024-02-09 21:24:54 +00:00
commit 01addab615
16 changed files with 249 additions and 171 deletions

3
.Xresources Normal file
View file

@ -0,0 +1,3 @@
#include ".Xresources.d/catppuccin-macchiato"
!#include ".Xresources.d/gruvbox-dark"
!#include ".Xresources.d/gruvbox-light"

View file

@ -0,0 +1,20 @@
! catppuccin color scheme
*.background: #24273A
*.foreground: #CAD3F5
*.cursorColor: #F4DBD6
*.color0: #494D64
*.color8: #5B6078
*.color1: #ED8796
*.color9: #ED8796
*.color2: #A6DA95
*.color10: #A6DA95
*.color3: #EED49F
*.color11: #EED49F
*.color4: #8AADF4
*.color12: #8AADF4
*.color5: #F5BDE6
*.color13: #F5BDE6
*.color6: #8BD5CA
*.color14: #8BD5CA
*.color7: #B8C0E0
*.color15: #A5ADCB

View file

@ -0,0 +1,27 @@
! gruvbox dark color scheme
! hard contrast:
! *.background: #1D2021
! soft contrast:
! *.background: #32302F
! deafult contrast:
*.background: #282828
*.foreground: #EBDBB2
*.cursorColor: #EBDBB2
*.color0: #282828
*.color8: #928374
*.color1: #CC241D
*.color9: #FB4934
*.color2: #98971A
*.color10: #B8BB26
*.color3: #D79921
*.color11: #FABD2F
*.color4: #458588
*.color12: #83A598
*.color5: #B16286
*.color13: #D3869B
*.color6: #689D6A
*.color14: #8EC07C
*.color7: #A89984
*.color15: #EBDBB2

View file

@ -0,0 +1,27 @@
!! gruvbox light color scheme
!! hard contrast:
!! *.background: #F9F5D7
!! soft contrast:
!! *.background: #F2E5BC
!! default contrast:
*.background: #FBF1C7
*.foreground: #3C3836
*.cursorColor: #3C3836
*.color0: #F9F5D7
*.color8: #928374
*.color1: #CC241D
*.color9: #9D0006
*.color2: #98971A
*.color10: #79740E
*.color3: #D79921
*.color11: #B57614
*.color4: #458588
*.color12: #076678
*.color5: #B16286
*.color13: #8F3F71
*.color6: #689D6A
*.color14: #427B58
*.color7: #7C6F64
*.color15: #3C3836

View file

@ -3,8 +3,8 @@ if status is-interactive
end end
export EDITOR="nvim" export EDITOR="nvim"
export TERMINAL="alacritty" export TERMINAL="st"
export TERMINAL_PROG="alacritty" export TERMINAL_PROG="st"
export BROWSER="firefox" export BROWSER="firefox"
export PAGER="bat" export PAGER="bat"

View file

@ -11,7 +11,7 @@
set $mod Mod1 set $mod Mod1
set $mod2 Mod4 set $mod2 Mod4
set $browser firefox set $browser firefox
set $terminal alacritty set $terminal st
# Font for window titles. Will also be used by the bar unless a different font # Font for window titles. Will also be used by the bar unless a different font
# is used in the bar {} block below. # is used in the bar {} block below.
@ -230,8 +230,10 @@ assign [class="discord"] 5
# startup programs # startup programs
exec --no-startup-id nextcloud exec --no-startup-id nextcloud
exec --no-startup-id nitrogen --restore exec --no-startup-id nitrogen --restore
exec --no-startup-id i3-msg 'workspace 2; exec firefox; workspace 1; exec $terminal' exec --no-startup-id i3-msg 'workspace 2; exec $browser'
exec --no-startup-id picom -b exec --no-startup-id i3-msg 'workspace 1; exec $terminal'
exec --no-startup-id openrgb -d 0 -m off -d 1 -m off exec --no-startup-id openrgb -d 0 -m off -d 1 -m off
# sets up monitors and picom
exec_always --no-startup-id ~/.local/share/scripts/monitor.sh
exec_always --no-startup-id ~/.config/polybar/launch.sh exec_always --no-startup-id ~/.config/polybar/launch.sh

View file

@ -1,5 +1,5 @@
require("tsousa.remap")
require("tsousa.set") require("tsousa.set")
require("tsousa.remap")
require("tsousa.lazy") require("tsousa.lazy")
local augroup = vim.api.nvim_create_augroup local augroup = vim.api.nvim_create_augroup
@ -12,6 +12,14 @@ function R(name)
require("plenary.reload").reload_module(name) require("plenary.reload").reload_module(name)
end end
autocmd('BufWinEnter',{
group= TsousaGroup,
pattern = '*',
callback = function()
vim.opt.formatoptions:remove('o')
end
})
autocmd('TextYankPost', { autocmd('TextYankPost', {
group = yank_group, group = yank_group,
pattern = '*', pattern = '*',
@ -46,7 +54,6 @@ autocmd("LspAttach", {
end end
}) })
vim.g.netrw_browse_split = 0 vim.g.netrw_browse_split = 0
vim.g.netrw_banner = 0 vim.g.netrw_banner = 0
vim.g.netrw_winsize = 25 vim.g.netrw_winsize = 25

View file

@ -1,6 +1,6 @@
local colour = "catppuccin" local color = "catppuccin"
function SetColour() function SetColor()
vim.cmd.colorscheme(colour) vim.cmd.colorscheme(color)
end end
return { return {
@ -20,13 +20,14 @@ return {
treesitter_context = true, treesitter_context = true,
fidget = true, fidget = true,
}, },
SetColour() SetColor()
}) })
end end
}, },
{ {
"ellisonleao/gruvbox.nvim", "ellisonleao/gruvbox.nvim",
priority = 1000,
config = function() config = function()
require("gruvbox").setup({ require("gruvbox").setup({
italic = { italic = {
@ -37,7 +38,7 @@ return {
}, },
transparent_mode = true, transparent_mode = true,
}) })
SetColour() SetColor()
end end
}, },
} }

View file

@ -104,20 +104,6 @@ return {
path = "[path]", path = "[path]",
}, },
}, },
-- format = function(entry, vim_item)
-- -- Kind icons
-- vim_item.kind = string.format("%s", kind_icons[vim_item.kind])
-- -- vim_item.kind = string.format('%s %s', kind_icons[vim_item.kind], vim_item.kind) -- This concatonates the icons with the name of the item kind
-- vim_item.menu = ({
-- buffer = "[buf]",
-- nvim_lsp = "[LSP]",
-- luasnip = "[snip]",
-- nvim_lsp_signature_help = "[Signature]",
-- nvim_lua = "[lua]",
-- path = "[path]",
-- })[entry.source.name]
-- return vim_item
-- end,
}, },
sources = cmp.config.sources( sources = cmp.config.sources(
{ {
@ -160,18 +146,6 @@ return {
cmp.config.compare.order, cmp.config.compare.order,
}, },
}, },
--confirm_opts = {
-- behavior = cmp.ConfirmBehavior.Replace,
-- select = false,
--},
-- window = {
-- documentation = cmp.config.window.bordered(),
-- completion = cmp.config.window.bordered({
-- winhighlight = "Normal:Pmenu,FloatBorder:Pmenu,CursorLine:PmenuSel,Search:None"
-- })
-- },
experimental = { experimental = {
ghost_text = true, ghost_text = true,
native_menu = false, native_menu = false,
@ -195,15 +169,16 @@ return {
} }
} }
}) })
vim.api.nvim_create_augroup("_mason", { clear = true }) vim.api.nvim_create_augroup("_mason", { clear = true })
require("mason").setup({ require("mason").setup({
PATH = "skip", PATH = "skip",
ui = { ui = {
icons = { icons = {
package_installed = "", package_installed = "",
package_pending = "", package_pending = "󱥸",
package_uninstalled = "" package_uninstalled = ""
}, }
}, },
max_concurrent_installers = 10, max_concurrent_installers = 10,
}) })
@ -226,9 +201,19 @@ return {
vim.keymap.set('n', '[d', vim.diagnostic.goto_prev) vim.keymap.set('n', '[d', vim.diagnostic.goto_prev)
vim.keymap.set('n', ']d', vim.diagnostic.goto_next) vim.keymap.set('n', ']d', vim.diagnostic.goto_next)
-- external (non mason) lsps
lspconfig.rust_analyzer.setup({
on_init = on_init,
flags = lsp_flags,
capabilities = capabilities,
cmd = {
"rustup", "run", "stable", "rust-analyzer",
}
})
mason_lspconfig.setup({ mason_lspconfig.setup({
ensure_installed = { ensure_installed = {
lua_ls,
}, },
automatic_installation = true, automatic_installation = true,
handlers = { handlers = {

View file

@ -1,6 +1,10 @@
vim.opt.guicursor="" vim.opt.wildignore = "__pycache__"
vim.opt.wildignore:append { "*.o", "*~", "*.pyc", "*pycache*" }
vim.opt.wildignore:append { "Cargo.lock", "Cargo.Bazel.lock" }
vim.opt.nu = true vim.opt.guicursor = ""
vim.opt.number = true
vim.opt.relativenumber = true vim.opt.relativenumber = true
vim.opt.errorbells = false vim.opt.errorbells = false
@ -22,7 +26,7 @@ vim.opt.showmode = false
vim.opt.hlsearch = false vim.opt.hlsearch = false
vim.opt.incsearch = true vim.opt.incsearch = true
vim.opt.showmatch = true
vim.opt.termguicolors = true vim.opt.termguicolors = true
vim.opt.scrolloff = 8 vim.opt.scrolloff = 8
@ -31,15 +35,15 @@ vim.opt.isfname:append("@-@")
-- from tj devries -- from tj devries
vim.opt.formatoptions = vim.opt.formatoptions vim.opt.formatoptions = vim.opt.formatoptions
- "o" -- O and o, don't continue comments
- "a" -- Auto formatting is BAD. - "a" -- Auto formatting is BAD.
- "t" -- Don't auto format my code. I got linters for that. - "t" -- Don't auto format my code. I got linters for that.
- "2" -- I'm not in gradeschool anymore
+ "c" -- In general, I like it when comments respect textwidth + "c" -- In general, I like it when comments respect textwidth
+ "q" -- Allow formatting comments w/ gq + "q" -- Allow formatting comments w/ gq
- "o" -- O and o, don't continue comments
+ "r" -- But do continue when pressing enter. + "r" -- But do continue when pressing enter.
+ "n" -- Indent past the formatlistpat, not underneath it. + "n" -- Indent past the formatlistpat, not underneath it.
+ "j" -- Auto-remove comments if possible. + "j" -- Auto-remove comments if possible.
- "2" -- I'm not in gradeschool anymore
-- Give more space for displaying messages. -- Give more space for displaying messages.
vim.opt.cmdheight = 1 vim.opt.cmdheight = 1
@ -51,7 +55,6 @@ vim.opt.updatetime = 50
-- Don't pass messages to |ins-completion-menu|. -- Don't pass messages to |ins-completion-menu|.
vim.opt.shortmess:append("c") vim.opt.shortmess:append("c")
vim.opt.colorcolumn="80" vim.opt.colorcolumn = "80"
vim.g.mapleader = " " vim.g.mapleader = " "

View file

@ -497,7 +497,7 @@ wintypes:
tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; }; tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };
dock = { shadow = false; } dock = { shadow = false; }
dnd = { shadow = false; } dnd = { shadow = false; }
popup_menu = { opacity = 0.8; } popup_menu = { opacity = 1; }
dropdown_menu = { opacity = 0.8; } dropdown_menu = { opacity = 1; }
}; };

View file

@ -17,7 +17,7 @@
;========================================================== ;==========================================================
include-file = modules.ini include-file = modules.ini
include-file = $HOME/.config/polybar/themes/macchiato.ini include-file = $HOME/.config/polybar/themes/xresources.ini
[settings] [settings]
screenchange-reload = true screenchange-reload = true
@ -43,8 +43,8 @@ modules-left = i3 sep title
modules-center = date dot time modules-center = date dot time
modules-right = xkeyboard dot cpu dot amdgpu dot memory dot pulseaudio sep filesystem modules-right = xkeyboard dot cpu dot amdgpu dot memory dot pulseaudio sep filesystem
background = ${colors.base} background = ${colors.background}
foreground = ${colors.text} foreground = ${colors.foreground}
line-size = 3pt line-size = 3pt
padding-right = 1 padding-right = 1
@ -67,8 +67,8 @@ modules-left = i3 sep title
modules-center = date dot time modules-center = date dot time
modules-right = xkeyboard dot cpu dot gpu dot memory dot backlight dot pulseaudio sep filesystem sep battery modules-right = xkeyboard dot cpu dot gpu dot memory dot backlight dot pulseaudio sep filesystem sep battery
background = ${colors.base} background = ${colors.background}
foreground = ${colors.text} foreground = ${colors.foreground}
line-size = 3pt line-size = 3pt
padding-right = 1 padding-right = 1
@ -90,8 +90,8 @@ modules-left = i3
modules-center = date dot time modules-center = date dot time
modules-right = cpu dot gpu dot memory dot pulseaudio sep filesystem modules-right = cpu dot gpu dot memory dot pulseaudio sep filesystem
background = ${colors.base} background = ${colors.background}
foreground = ${colors.text} foreground = ${colors.foreground}
line-size = 3pt line-size = 3pt
padding-right = 1 padding-right = 1

View file

@ -13,8 +13,8 @@ format = <label-state> <label-mode>
label-mode = %mode% label-mode = %mode%
label-mode-padding = 1 label-mode-padding = 1
label-focused = %index% label-focused = %index%
label-focused-foreground = ${colors.text} label-focused-foreground = ${colors.foreground}
label-focused-underline = ${colors.lavender} label-focused-underline = ${colors.lightgrey}
label-focused-padding = 1 label-focused-padding = 1
label-unfocused = %index% label-unfocused = %index%
label-unfocused-padding = 1 label-unfocused-padding = 1
@ -28,8 +28,8 @@ label-urgent-padding = 1
[module/xworkspaces] [module/xworkspaces]
type = internal/xworkspaces type = internal/xworkspaces
label-active = %name% label-active = %name%
label-active-foreground = ${colors.sky} label-active-foreground = ${colors.lightblue}
label-active-underline= ${colors.lavender} label-active-underline= ${colors.lightgrey}
label-active-padding = 1 label-active-padding = 1
label-occupied = %name% label-occupied = %name%
label-occupied-padding = 1 label-occupied-padding = 1
@ -44,20 +44,20 @@ type = internal/xkeyboard
format = <label-layout> format = <label-layout>
format-prefix = 󰌌 format-prefix = 󰌌
format-prefix-foreground = ${colors.mauve} format-prefix-foreground = ${colors.magenta}
format-prefix-padding-right = 1 format-prefix-padding-right = 1
format-spacing = 0 format-spacing = 0
label-layout = %layout% label-layout = %layout%
label-layout-padding = 0 label-layout-padding = 0
label-layout-background = ${colors.base} label-layout-background = ${colors.background}
label-layout-foreground = ${colors.text} label-layout-foreground = ${colors.foreground}
[module/title] [module/title]
type = internal/xwindow type = internal/xwindow
format = <label> format = <label>
;format-foreground = ${colors.text} ;format-foreground = ${colors.foreground}
format-padding = 2 format-padding = 2
label = %title% label = %title%
@ -117,7 +117,7 @@ interval = 1
label = %used% label = %used%
format = <label> format = <label>
format-prefix = 󰘚 format-prefix = 󰘚
format-prefix-foreground = ${colors.peach} format-prefix-foreground = ${colors.magenta}
format-prefix-padding-right = 1 format-prefix-padding-right = 1
[module/filesystem] [module/filesystem]
@ -138,18 +138,18 @@ interval = 5
format-volume = <ramp-volume><label-volume> format-volume = <ramp-volume><label-volume>
label-volume = %percentage%% label-volume = %percentage%%
ramp-volume-0 = 󰕿 ramp-volume-0 = 󰕿
ramp-volume-0-foreground = ${colors.teal} ramp-volume-0-foreground = ${colors.lightgreen}
ramp-volume-0-padding-right = 1 ramp-volume-0-padding-right = 1
ramp-volume-1 = 󰖀 ramp-volume-1 = 󰖀
ramp-volume-1-foreground = ${colors.teal} ramp-volume-1-foreground = ${colors.lightgreen}
ramp-volume-1-padding-right = 1 ramp-volume-1-padding-right = 1
ramp-volume-2 = 󰕾 ramp-volume-2 = 󰕾
ramp-volume-2-foreground = ${colors.teal} ramp-volume-2-foreground = ${colors.lightgreen}
ramp-volume-2-padding-right = 1 ramp-volume-2-padding-right = 1
label-muted = MUTED label-muted = MUTED
label-muted-foreground = ${colors.subtext0} label-muted-foreground = ${colors.lightgrey}
format-muted-prefix = 󰝟 format-muted-prefix = 󰝟
format-muted-prefix-foreground = ${colors.maroon} format-muted-prefix-foreground = ${colors.red}
format-muted-prefix-padding-right = 1 format-muted-prefix-padding-right = 1
click-right = pavucontrol || pulseaudio-equalizer-ladspa || pulseeffects || easyeffects click-right = pavucontrol || pulseaudio-equalizer-ladspa || pulseeffects || easyeffects
@ -286,7 +286,7 @@ date = %a, %B %d
label = %date% label = %date%
format = <label> format = <label>
format-prefix = 󰃭 format-prefix = 󰃭
format-prefix-foreground = ${colors.rosewater} format-prefix-foreground = ${colors.lightyellow}
format-prefix-padding-right = 1 format-prefix-padding-right = 1
[module/time] [module/time]
@ -296,25 +296,25 @@ time = %H:%M
label = %time% label = %time%
format = <label> format = <label>
format-prefix = 󰥔 format-prefix = 󰥔
format-prefix-foreground = ${colors.pink} format-prefix-foreground = ${colors.lightmagenta}
format-prefix-padding-right = 1 format-prefix-padding-right = 1
[module/space] [module/space]
type = custom/text type = custom/text
content = _ content = _
content-foreground = ${colors.crust} content-foreground = ${colors.background}
content-padding = 0.5 content-padding = 0.5
[module/dot] [module/dot]
type = custom/text type = custom/text
content = 󰧞 content = 󰧞
content-foreground = ${colors.overlay0} content-foreground = ${colors.grey}
content-padding = 1 content-padding = 1
[module/sep] [module/sep]
type = custom/text type = custom/text
content = | content = |
content-foreground = ${colors.overlay0} content-foreground = ${colors.grey}
content-padding = 1 content-padding = 1

View file

@ -1,5 +1,5 @@
set -g default-terminal "tmux-256color" set -g default-terminal "tmux-256color"
set -ag terminal-overrides ",xterm-256color:RGB" set -ag terminal-overrides ",*:RGB"
unbind C-b unbind C-b
set-option -g prefix C-a set-option -g prefix C-a

View file

@ -11,3 +11,6 @@ else
xrandr --output HDMI-1-0 --above eDP-1 xrandr --output HDMI-1-0 --above eDP-1
xrandr --output HDMI-1-0 --primary xrandr --output HDMI-1-0 --primary
fi fi
pkill picom
picom -b

View file

@ -4,7 +4,7 @@
if [[ $# -eq 1 ]]; then if [[ $# -eq 1 ]]; then
selected=$1 selected=$1
else else
selected=$(find ~/.config ~/gits ~/2sem ~/ -mindepth 1 -maxdepth 1 -type d,l | fzf) selected=$(find ~/Nextcloud ~/.config ~/gits ~/2sem ~/ -mindepth 1 -maxdepth 1 -type d,l | fzf)
fi fi
if [[ -z "$selected" ]]; then if [[ -z "$selected" ]]; then