Compare commits

..

No commits in common. "c0d17922f9f9ec276e6ae60ecf667ff803925f4d" and "3b163629e03de29ec1ab1d1187e73887e939bc77" have entirely different histories.

16 changed files with 180 additions and 144 deletions

View file

@ -15,9 +15,7 @@ for_window [class="Klipper"] floating enable; border none
for_window [class="Plasmoidviewer"] floating enable; border none for_window [class="Plasmoidviewer"] floating enable; border none
# for_window [class="(?i)*nextcloud*"] floating disable # for_window [class="(?i)*nextcloud*"] floating disable
for_window [class="plasmashell" window_type="notification"] border none, move position 70 ppt 81 ppt no_focus [class="plasmashell" window_type="notification"] for_window [class="plasmashell" window_type="notification"] border none, move position 70 ppt 81 ppt no_focus [class="plasmashell" window_type="notification"]
for_window [class="(.*join\?action\=join.*|.*zoom.*)"] floating enable
for_window [class="(.*join\?action\=join.*|.*zoom.*)" title="Zoom - Licensed Account"] floating disable
for_window [class="(.*join\?action\=join.*|.*zoom.*)" title="Zoom Meeting"] floating disable
# no title bars # no title bars
default_border pixel 4 default_border pixel 4
default_floating_border pixel 4 default_floating_border pixel 4

View file

@ -1,16 +0,0 @@
local mark = require('harpoon.mark')
local ui = require('harpoon.ui')
local cmd_ui = require('harpoon.cmd-ui')
local term = require('harpoon.term')
vim.keymap.set('n', '<leader>a', mark.add_file)
vim.keymap.set('n', '<C-e>', ui.toggle_quick_menu)
vim.keymap.set('n', '<C-h>', function() ui.nav_file(1) end)
vim.keymap.set('n', '<C-t>', function() ui.nav_file(2) end)
vim.keymap.set('n', '<C-n>', function() ui.nav_file(3) end)
vim.keymap.set('n', '<C-s>', function() ui.nav_file(4) end)
vim.keymap.set('n', '<leader>c', cmd_ui.toggle_quick_menu)
vim.keymap.set('n', '<leader>gt1', function() term.gotoTerminal(1) end)
vim.keymap.set('n', '<leader>br', function() term.sendCommand(1, 'build_ros') end)

View file

@ -9,16 +9,7 @@ require('mason-lspconfig').setup {
'lua_ls', 'clangd', 'pylsp', 'yamlls' 'lua_ls', 'clangd', 'pylsp', 'yamlls'
} }
} }
local lsp = require('lsp-zero').preset({ local lsp = require('lsp-zero').preset({})
manage_nvim_cmp = {
set_sources = 'lsp',
set_basic_mappings = true,
set_extra_mappings = false,
use_luasnip = true,
set_format = true,
documentation_window = true,
}
})
lsp.on_attach(function(client, bufnr) lsp.on_attach(function(client, bufnr)
lsp.default_keymaps({ buffer = bufnr }) lsp.default_keymaps({ buffer = bufnr })
@ -41,7 +32,6 @@ cmp.setup({
['<C-space>'] = cmp.mapping.complete(), ['<C-space>'] = cmp.mapping.complete(),
['<C-j>'] = cmp.mapping.scroll_docs(1), ['<C-j>'] = cmp.mapping.scroll_docs(1),
['<C-k>'] = cmp.mapping.scroll_docs(-1), ['<C-k>'] = cmp.mapping.scroll_docs(-1),
['<CR>'] = cmp.mapping.confirm({ select = false }),
}, },
window = { window = {
completion = cmp.config.window.bordered(), completion = cmp.config.window.bordered(),

View file

@ -1,17 +1 @@
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" require("lennartalff")
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable", -- latest stable release
lazypath,
})
end
vim.opt.rtp:prepend(lazypath)
vim.g.mapleader = ' ' -- needs to be set before lazy im
require('lazy').setup('plugins')
require('lennartalff')

View file

@ -1,5 +1,4 @@
require('lennartalff.remap') require('lennartalff.remap')
require('lennartalff.packer')
require('lennartalff.set') require('lennartalff.set')
-- vim.cmd('colorscheme rose-pine') vim.cmd('colorscheme rose-pine')
vim.o.termguicolors = true
vim.cmd.colorscheme 'catppuccin-frappe'

View file

@ -1,16 +1,4 @@
-- packer bootstrapping vim.cmd [[packadd packer.nvim]]
local ensure_packer = function()
local fn = vim.fn
local install_path = fn.stdpath('data') .. '/site/pack/packer/start/packer.nvim'
if fn.empty(fn.glob(install_path)) > 0 then
fn.system({ 'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path })
vim.cmd [[packadd packer.nvim]]
return true
end
return false
end
local packer_bootstrap = ensure_packer()
return require('packer').startup(function(use) return require('packer').startup(function(use)
-- Packer can manage itself -- Packer can manage itself
@ -59,7 +47,4 @@ return require('packer').startup(function(use)
{ "nvim-treesitter/nvim-treesitter" } { "nvim-treesitter/nvim-treesitter" }
} }
} }
if packer_bootstrap then
require('packer').sync()
end
end) end)

View file

@ -28,20 +28,7 @@ vim.keymap.set('n', '<leader>f', function()
end) end)
-- quickfix navigation -- quickfix navigation
vim.keymap.set('n', '<C-j>', '<cmd>cnext<CR>zz') vim.keymap.set('n', '<C-k>', '<cmd>cnext<CR>zz')
vim.keymap.set('n', '<C-k>', '<cmd>cprev<CR>zz') vim.keymap.set('n', '<C-j>', '<cmd>cprev<CR>zz')
vim.keymap.set('n', '<leader>j', '<cmd>lnext<CR>zz') vim.keymap.set('n', '<leader>k', '<cmd>lnext<CR>zz')
vim.keymap.set('n', '<leader>k', '<cmd>lprev<CR>zz') vim.keymap.set('n', '<leader>j', '<cmd>lprev<CR>zz')
vim.keymap.set('n', '<leader>i', vim.lsp.buf.hover)
vim.keymap.set('n', '<leader>r', vim.lsp.buf.rename)
vim.keymap.set('n', '<leader>dq', vim.diagnostic.setqflist)
local function quickfix()
vim.lsp.buf.code_action({
filter = function(a) return a.isPreferred end,
apply = true
})
end
vim.keymap.set('n', '<leader>qf', quickfix)

View file

@ -1,36 +0,0 @@
return {
{ 'nvim-treesitter/nvim-treesitter', build = ':TSUpdate' },
'lewis6991/gitsigns.nvim',
{
'nvim-telescope/telescope.nvim',
dependencies = {
{ 'nvim-lua/plenary.nvim' } }
},
{ 'rose-pine/neovim', name = 'rose-pine' },
{ 'catppuccin/nvim', name = 'catppuccin', priority = 1000 },
{ 'tpope/vim-fugitive', name = 'fugitive' },
{
'VonHeikemen/lsp-zero.nvim',
branch = 'v2.x',
dependencies = {
-- LSP Support
{ 'neovim/nvim-lspconfig' }, -- Required
{ 'williamboman/mason.nvim' }, -- Optional
{ 'williamboman/mason-lspconfig.nvim' }, -- Optional
-- Autocompletion
{ 'hrsh7th/nvim-cmp' }, -- Required
{ 'hrsh7th/cmp-nvim-lsp' }, -- Required
{ 'L3MON4D3/LuaSnip' }, -- Required
},
},
{
'ThePrimeagen/harpoon',
dependencies = {
{ 'nvim-lua/plenary.nvim' },
},
},
{ 'ray-x/lsp_signature.nvim', event = 'VeryLazy', opts = {},
config = function(_, opts) require('lsp_signature').setup(opts) end },
}

View file

@ -0,0 +1,164 @@
-- Automatically generated packer.nvim plugin loader code
if vim.api.nvim_call_function('has', {'nvim-0.5'}) ~= 1 then
vim.api.nvim_command('echohl WarningMsg | echom "Invalid Neovim version for packer.nvim! | echohl None"')
return
end
vim.api.nvim_command('packadd packer.nvim')
local no_errors, error_msg = pcall(function()
_G._packer = _G._packer or {}
_G._packer.inside_compile = true
local time
local profile_info
local should_profile = false
if should_profile then
local hrtime = vim.loop.hrtime
profile_info = {}
time = function(chunk, start)
if start then
profile_info[chunk] = hrtime()
else
profile_info[chunk] = (hrtime() - profile_info[chunk]) / 1e6
end
end
else
time = function(chunk, start) end
end
local function save_profiles(threshold)
local sorted_times = {}
for chunk_name, time_taken in pairs(profile_info) do
sorted_times[#sorted_times + 1] = {chunk_name, time_taken}
end
table.sort(sorted_times, function(a, b) return a[2] > b[2] end)
local results = {}
for i, elem in ipairs(sorted_times) do
if not threshold or threshold and elem[2] > threshold then
results[i] = elem[1] .. ' took ' .. elem[2] .. 'ms'
end
end
if threshold then
table.insert(results, '(Only showing plugins that took longer than ' .. threshold .. ' ms ' .. 'to load)')
end
_G._packer.profile_output = results
end
time([[Luarocks path setup]], true)
local package_path_str = "/home/lennartalff/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/home/lennartalff/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/home/lennartalff/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/home/lennartalff/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua"
local install_cpath_pattern = "/home/lennartalff/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so"
if not string.find(package.path, package_path_str, 1, true) then
package.path = package.path .. ';' .. package_path_str
end
if not string.find(package.cpath, install_cpath_pattern, 1, true) then
package.cpath = package.cpath .. ';' .. install_cpath_pattern
end
time([[Luarocks path setup]], false)
time([[try_loadstring definition]], true)
local function try_loadstring(s, component, name)
local success, result = pcall(loadstring(s), name, _G.packer_plugins[name])
if not success then
vim.schedule(function()
vim.api.nvim_notify('packer.nvim: Error running ' .. component .. ' for ' .. name .. ': ' .. result, vim.log.levels.ERROR, {})
end)
end
return result
end
time([[try_loadstring definition]], false)
time([[Defining packer_plugins]], true)
_G.packer_plugins = {
LuaSnip = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/LuaSnip",
url = "https://github.com/L3MON4D3/LuaSnip"
},
["cmp-nvim-lsp"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp",
url = "https://github.com/hrsh7th/cmp-nvim-lsp"
},
["formatter.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/formatter.nvim",
url = "https://github.com/mhartington/formatter.nvim"
},
["lsp-zero.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/lsp-zero.nvim",
url = "https://github.com/VonHeikemen/lsp-zero.nvim"
},
["mason-lspconfig.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/mason-lspconfig.nvim",
url = "https://github.com/williamboman/mason-lspconfig.nvim"
},
["mason.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/mason.nvim",
url = "https://github.com/williamboman/mason.nvim"
},
["nvim-cmp"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/nvim-cmp",
url = "https://github.com/hrsh7th/nvim-cmp"
},
["nvim-lspconfig"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/nvim-lspconfig",
url = "https://github.com/neovim/nvim-lspconfig"
},
["nvim-treesitter"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/nvim-treesitter",
url = "https://github.com/nvim-treesitter/nvim-treesitter"
},
["packer.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/packer.nvim",
url = "https://github.com/wbthomason/packer.nvim"
},
["plenary.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/plenary.nvim",
url = "https://github.com/nvim-lua/plenary.nvim"
},
["rose-pine"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/rose-pine",
url = "https://github.com/rose-pine/neovim"
},
["telescope.nvim"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/telescope.nvim",
url = "https://github.com/nvim-telescope/telescope.nvim"
},
["vim-fugitive"] = {
loaded = true,
path = "/home/lennartalff/.local/share/nvim/site/pack/packer/start/vim-fugitive",
url = "https://github.com/tpope/vim-fugitive"
}
}
time([[Defining packer_plugins]], false)
_G._packer.inside_compile = false
if _G._packer.needs_bufread == true then
vim.cmd("doautocmd BufRead")
end
_G._packer.needs_bufread = false
if should_profile then save_profiles() end
end)
if not no_errors then
error_msg = error_msg:gsub('"', '\\"')
vim.api.nvim_command('echohl ErrorMsg | echom "Error in packer_compiled: '..error_msg..'" | echom "Please check your config for correctness" | echohl None')
end

View file

@ -26,7 +26,6 @@ alert = #E60053
disabled = #707880 disabled = #707880
[bar/bar1] [bar/bar1]
monitor = ${env:MONITOR:}
width = 100% width = 100%
height = 24pt height = 24pt
radius = 6 radius = 6
@ -73,7 +72,6 @@ tray-maxsize = 96
; override-redirect = true ; override-redirect = true
[module/xworkspaces] [module/xworkspaces]
pin-workspaces = true
type = internal/xworkspaces type = internal/xworkspaces
label-active = %name% label-active = %name%

View file

@ -4,12 +4,4 @@
polybar-msg cmd quit polybar-msg cmd quit
echo "---" | tee -a /tmp/polybar1.log echo "---" | tee -a /tmp/polybar1.log
if type "xrandr"; then polybar bar1 2>&1 | tee -a /tmp/polybar1.log & disown
for m in $(xrandr --query | grep " connected" | cut -d" " -f1); do
MONITOR=$m polybar --reload bar1 &
done
else
polybar --reload bar1 &
fi
# polybar bar1 2>&1 | tee -a /tmp/polybar1.log & disown

View file

@ -10,14 +10,10 @@ super + {_, shift +, ctrl +} {h, j, k, l}
super + r: {h, j, k, l} super + r: {h, j, k, l}
i3-msg resize {shrink width, grow height, shrink height, grow width} 10 px or 10 ppt i3-msg resize {shrink width, grow height, shrink height, grow width} 10 px or 10 ppt
# move floating mode
super + m: {h, j, k, l}
i3-msg move {left, down, up, right}
super + {_, shift +} d super + {_, shift +} d
i3-msg "exec --no-startup-id {i3-dmenu-desktop, dmenu_run}" i3-msg "exec --no-startup-id {i3-dmenu-desktop, dmenu_run}"
super + {_, shift +} n super + {_, shift +} n
dunstctl {history-pop, close} dunstctl {history-pop, close}
super + space super + shift + space
i3-msg floating toggle i3-msg floating toggle

2
.gitignore vendored
View file

@ -1,3 +1 @@
/backup /backup
**/packer_compiled.lua
.config/nvim/lazy-lock.json

View file

@ -6,7 +6,7 @@ grep -v "^#" pkglist.txt | sudo pacman -S --needed -
~~~ ~~~
``` bash ``` bash
grep -v "^#" pkglist_aur.txt | yay -S --needed --noconfirm - grep -v "^#" pkglist_aur.txt | yay -S --needed -
``` ```
## IBus Configuration ## IBus Configuration

View file

@ -89,6 +89,9 @@ else
export EDITOR='vim' export EDITOR='vim'
fi fi
export TERM="xterm-256color"
alias reboot-windows="systemctl reboot --boot-loader-entry=windows.conf" alias reboot-windows="systemctl reboot --boot-loader-entry=windows.conf"
alias reboot-linux="systemctl reboot --boot-loader-entry=arch.conf" alias reboot-linux="systemctl reboot --boot-loader-entry=arch.conf"
alias zshrc="vim ~/.zshrc" alias zshrc="vim ~/.zshrc"
@ -96,6 +99,4 @@ alias zshrc="vim ~/.zshrc"
alias mount-institut='kinit -kt "$HOME/keytabs/cta1233.keytab" cta1233@KERBEROS.TU-HARBURG.DE && mount /TUHH/Institut' alias mount-institut='kinit -kt "$HOME/keytabs/cta1233.keytab" cta1233@KERBEROS.TU-HARBURG.DE && mount /TUHH/Institut'
alias mount-lehre='kinit -kt "$HOME/keytabs/cta1233.keytab" cta1233@KERBEROS.TU-HARBURG.DE && mount /TUHH/Lehre' alias mount-lehre='kinit -kt "$HOME/keytabs/cta1233.keytab" cta1233@KERBEROS.TU-HARBURG.DE && mount /TUHH/Lehre'
alias rosterm='docker exec -it ros2-vim zsh'
alias git-delete-merged="git branch --merged main | grep -v '^[ *]*main$' | xargs git branch -d" alias git-delete-merged="git branch --merged main | grep -v '^[ *]*main$' | xargs git branch -d"

View file

@ -16,7 +16,3 @@ arandr
autorandr autorandr
redshift redshift
ripgrep ripgrep
# provider for clipboard in nvim
xsel
# for locking the screen with loginctl
xss-lock