Compare commits

...

59 Commits

Author SHA1 Message Date
don philipe 15240d7e86 Add zsh function to run git commands for codebase diagnose 2026-04-21 17:32:32 +02:00
don philipe 97e16f6273 Merge branch 'master' of https://github.com/don-philipe/dotfiles 2026-03-27 19:42:48 +01:00
don philipe 16d1175f21 Add pem-to-crt with openssl zsh func 2026-03-26 10:11:57 +01:00
don philipe 5ede1b3b47 Merge branch 'master' of https://github.com/don-philipe/dotfiles 2026-03-20 10:40:49 +01:00
don philipe 6033bd016e Add nvim dap, parrot 2026-03-20 10:40:42 +01:00
don philipe 4f6b390ba6 Disable lazy change_detection due to possible memory leakage 2026-03-17 13:03:37 +01:00
don philipe 1b6cad45f5 Add shortcuts for staging hunks and buffers 2026-03-11 10:19:11 +01:00
don philipe b648f0a936 Fix cmp borders by setting them globally 2026-02-18 10:28:56 +01:00
don philipe 434df00be3 Add LSP helper plugin for python lang 2026-02-17 14:26:00 +01:00
don philipe 6a82e1dc6f Add detection of ansible files in nvim 2026-02-17 14:24:19 +01:00
don philipe 081a2f5498 Switch to parrot as LLM plugin for nvim 2026-02-17 13:27:31 +01:00
don philipe d6707b3dff nvim persist undo after file closing 2025-11-10 21:52:36 +01:00
don philipe d3494b9830 Add rainbow csv nvim plugin 2025-09-26 10:28:25 +02:00
don philipe f6bbc705f8 Add latex to treesitter config 2025-09-23 23:14:08 +02:00
don philipe 30d3a8c29a Merge neovim settings 2025-09-04 09:20:03 +02:00
don philipe a414890f69 Fix coloring in nvim in tmux remote sessions 2025-09-04 04:53:16 +02:00
don philipe 2df66474db Merge zsh functions 2025-09-04 04:51:08 +02:00
don philipe 3e30bb71a0 Add zsh function to list all git blobs in a repo 2025-09-02 13:23:45 +02:00
don philipe 177716cdbe Find dotfiles when they are not gitignored 2025-09-01 13:09:47 +02:00
don philipe f8cf65bda9 Add doxx for docx file preview in ranger 2025-08-19 10:27:11 +02:00
don philipe bea47efec4 Keymap for resetting hunk 2025-08-18 09:47:29 +02:00
don philipe 10de9c300b Add diffview nvim plugin 2025-08-14 10:39:43 +02:00
don philipe 5feff36b73 Add redmine plugin to nvim 2025-06-17 10:53:54 +02:00
don philipe 8f50d2cb75 Add TypeScript LSP 2025-06-17 10:52:04 +02:00
don philipe b62f1697a2 Ensure autoreload works with nvim+tmux 2025-06-05 09:38:51 +02:00
don philipe 4260c7876c Add nvim plugins for showing context and indent lines 2025-06-05 00:50:19 +02:00
don philipe ff7deb9cee Shortcut for preview hunk 2025-05-26 13:47:16 +02:00
don philipe f84673ed16 gitsigns.nvim vertical split 2025-05-26 13:42:02 +02:00
don philipe 5bdd07c204 Pin gitsigns version 2025-05-14 13:36:26 +02:00
don philipe 469435454e Pin mason version 2025-05-14 10:17:44 +02:00
don philipe 3e51152da9 Search hidden files with telescope 2025-05-14 10:11:37 +02:00
don philipe 6a710bac5f Switch to new diff pane after gitsigns diffthis 2025-04-24 14:21:22 +02:00
don philipe af50ddd8ea Add rounded borders for completion plugin 2025-04-23 22:04:41 +02:00
don philipe 7128760315 Add rounded borders for lazy plugin manager 2025-04-23 22:03:35 +02:00
don philipe f078314b0d Custom nvim indents for various filetypes 2025-04-23 22:02:28 +02:00
don philipe 9803f705e4 Pin version of nvim plugins lsp and treesitter
For using named plugins with neovim < 0.10 plugin versions not above a
certain value are needed.
2025-04-08 12:50:46 +02:00
don philipe b3d8e46003 Set LLM_KEY env var in nvim config 2025-04-02 09:17:12 +02:00
don philipe cfafeb5c04 Find selected text via telescope 2025-03-25 11:28:12 +01:00
don philipe 33f864dea8 Merge alacritty config 2025-03-25 09:48:43 +01:00
don philipe 7b473872b4 Add tmux option for true color over ssh 2025-03-25 09:44:38 +01:00
don philipe 6934c87709 Set xterm-256color in terminal conf to have true color in remote tmux sessions 2025-03-24 15:48:31 +01:00
don philipe 6f4a75353f Set terminal font 2025-03-24 15:47:50 +01:00
don philipe ec3b6b27b7 Change nvim telescope layout 2025-03-13 14:18:20 +01:00
don philipe 5f1950d6ff Shortcut <leader>gd to show diff 2025-03-11 13:01:31 +01:00
don philipe 2d49086536 Show filepath in lualine 2025-03-10 12:51:34 +01:00
don philipe 6f0dc2af55 <leader>h or <leader>H to jump between hunks 2025-03-10 12:37:35 +01:00
don philipe be00da9268 Custom nvim gen command adding https schema 2025-02-19 11:21:28 +01:00
don philipe c9e3b33958 Add JSON formatting command to nvim 2025-02-17 10:44:08 +01:00
don philipe 550afd3996 Add run and paste mapping to neovim 2025-02-13 13:36:42 +01:00
don philipe d085ff6fe5 Shortcut <leader>gm to show git message for current line 2025-02-06 13:04:56 +01:00
don philipe 98d048721e Add nvim plugin telescope for finding files etc. 2025-02-06 10:33:07 +01:00
don philipe afd41cae41 Add gitsigns and lualine plugins 2025-02-05 12:34:13 +01:00
don philipe 6189d2e969 Merge branch 'master' of https://github.com/don-philipe/dotfiles 2025-01-23 09:41:17 +01:00
don philipe 01ce55d107 Add neovim config with some plugins 2025-01-22 22:29:58 +01:00
don philipe 5d692852f6 Split alacritty config in sections 2025-01-13 09:59:52 +01:00
don philipe f303f1aa1d Avoid logging space prefixed commands to hist file like qrcode 2025-01-03 15:16:10 +01:00
don philipe 5db8c17379 Fix deprecated alacritty config 2024-11-30 13:42:58 +01:00
don philipe 62e72cafe3 Set autorestore on for tmux resurrect 2024-10-16 10:45:23 +02:00
don philipe 6cf7031cfe Merge tmux conf 2024-10-14 11:16:52 +02:00
39 changed files with 577 additions and 9 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ URxvt.foreground: white
!URxvt.borderColor: dark grey !URxvt.borderColor: dark grey
URxvt.scrollBar: false URxvt.scrollBar: false
URxvt.cursorColor: green URxvt.cursorColor: green
URxvt.font: xft:monospace:size=9,xft:Noto Color Emoji URxvt.font: xft:Jet Brains Mono Nerd Font:size=9,xft:monospace:size=9,xft:Noto Color Emoji
URxvt.perl-ext-common: default,matcher URxvt.perl-ext-common: default,matcher
URxvt.url-launcher: /usr/bin/xdg-open URxvt.url-launcher: /usr/bin/xdg-open
URxvt.matcher.button: 1 URxvt.matcher.button: 1
+17 -5
View File
@@ -1,10 +1,22 @@
# https://github.com/alacritty/alacritty-theme
import = ["~/.config/alacritty/themes/themes/gruvbox_dark.toml"]
shell = "/bin/zsh"
[colors.cursor] [colors.cursor]
cursor = "#00ff00" cursor = "#00ff00"
text = "#000000" text = "#000000"
[env]
# set this to have true color when using nvim etc. in remote tmux session
TERM = "xterm-256color"
WINIT_X11_SCALE_FACTOR = "1.0"
[font] [font]
size = 10 size = 9
[font.normal]
family = "Jet Brains Mono Nerd Font"
#family = "Mononoki Nerd Font"
[general]
# https://github.com/alacritty/alacritty-theme
import = ["~/.config/alacritty/themes/themes/gruvbox_dark.toml"]
[terminal]
shell = "/bin/zsh"
+43
View File
@@ -0,0 +1,43 @@
-- utilities functions
--require("utils")
require("config.remap")
require("config.set")
require("config.commands")
-- env vars used only for neovim
require("config.env")
-- configurations for various filetypes
require("config.filetypes")
-- plugin manager
require("config.lazy")
-- plugins
require("config.cmp")
require("config.lsp")
require("config.mason")
require("config.treesitter")
require("config.treesitter-context")
require("config.gitsigns")
require("config.lualine")
require("config.telescope")
require("config.indentline")
--require("config.redmine")
require("config.diffview")
require("config.dap")
require("config.parrot")
--require("config.gitea")
-- for some reason this must be placed in init.lua file
-- it doesn't work in any lua/config/*.lua files
require('lspconfig').pylsp.setup {
settings = {
pylsp = {
plugins = {
pycodestyle = {
maxLineLength = 120,
},
},
},
},
}
+33
View File
@@ -0,0 +1,33 @@
-- autocompletion
local cmp = require('cmp')
cmp.setup({
sources = {
{name = 'nvim_lsp'},
},
mapping = cmp.mapping.preset.insert({
-- Navigate between completion items
['<C-p>'] = cmp.mapping.select_prev_item({behavior = 'select'}),
['<C-n>'] = cmp.mapping.select_next_item({behavior = 'select'}),
-- `Enter` key to confirm completion
['<CR>'] = cmp.mapping.confirm({select = false}),
-- Ctrl+Space to trigger completion menu
['<C-Space>'] = cmp.mapping.complete(),
-- Scroll up and down in the completion documentation
['<C-u>'] = cmp.mapping.scroll_docs(-4),
['<C-d>'] = cmp.mapping.scroll_docs(4),
}),
snippet = {
expand = function(args)
vim.snippet.expand(args.body)
end,
},
-- switch on rounded borders in floating completion windows
-- additionally vim.o.winborder = 'rounded' must be set (set.lua)
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
})
+3
View File
@@ -0,0 +1,3 @@
vim.api.nvim_create_user_command('JQ', function()
vim.cmd('%!jq .')
end, {})
+2
View File
@@ -0,0 +1,2 @@
require("diffview").setup({
})
+1
View File
@@ -0,0 +1 @@
vim.env.LLM_KEY = "None"
+67
View File
@@ -0,0 +1,67 @@
vim.api.nvim_create_autocmd('Filetype', {
pattern = {
'xml',
'html',
'xhtml',
'css',
'scss',
'javascript',
'typescript',
'lua',
'jsx',
'tsx',
'typescriptreact',
'javascriptreact',
'htmldjango'
},
command = 'setlocal shiftwidth=4 tabstop=4 expandtab'
})
vim.api.nvim_create_autocmd('Filetype', {
pattern = { 'yaml',
},
command = 'setlocal shiftwidth=2 tabstop=2 expandtab'
})
if vim.filetype then
vim.filetype.add({
pattern = {
[".*/defaults/.*%.ya?ml"] = "yaml.ansible",
[".*/host_vars/.*%.ya?ml"] = "yaml.ansible",
[".*/group_vars/.*%.ya?ml"] = "yaml.ansible",
[".*/group_vars/.*/.*%.ya?ml"] = "yaml.ansible",
[".*/playbook.*%.ya?ml"] = "yaml.ansible",
[".*/playbooks/.*%.ya?ml"] = "yaml.ansible",
[".*/roles/.*/tasks/.*%.ya?ml"] = "yaml.ansible",
[".*/roles/.*/handlers/.*%.ya?ml"] = "yaml.ansible",
[".*/tasks/.*%.ya?ml"] = "yaml.ansible",
[".*/molecule/.*%.ya?ml"] = "yaml.ansible",
},
})
else
vim.api.nvim_create_autocmd({ "BufRead", "BufNewFile" }, {
pattern = {
"*/defaults/*.yml",
"*/defaults/*.yaml",
"*/host_vars/*.yml",
"*/host_vars/*.yaml",
"*/group_vars/*.yml",
"*/group_vars/*.yaml",
"*/group_vars/*/*.yml",
"*/group_vars/*/*.yaml",
"*/playbook*.yml",
"*/playbook*.yaml",
"*/playbooks/*.yml",
"*/playbooks/*.yaml",
"*/roles/*/tasks/*.yml",
"*/roles/*/tasks/*.yaml",
"*/roles/*/handlers/*.yml",
"*/roles/*/handlers/*.yaml",
"*/tasks/*.yml",
"*/tasks/*.yaml",
"*/molecule/*.yml",
"*/molecule/*.yaml",
},
callback = function()
vim.bo.filetype = "yaml.ansible"
end,
})
end
+11
View File
@@ -0,0 +1,11 @@
-- return {
-- model = "llama3.2",
-- host = "jupiter",
-- port = "11434",
-- }
return {
model = "llama3.3",
host = "owu-zegv-api.med.tu-dresden.de",
port = "443",
https = true,
}
+11
View File
@@ -0,0 +1,11 @@
require('gitsigns').setup()
local gitsigns = require('gitsigns')
vim.keymap.set('n', '<leader>gm', gitsigns.blame_line, { desc = 'Show git message for current line' })
vim.keymap.set('n', '<leader>gd', ':Gitsigns diffthis ~ vertical=true<CR>:wincmd w<CR>', { desc = 'Show diff for current line' })
vim.keymap.set('n', '<leader>gs', gitsigns.stage_hunk, { desc = 'Stage current hunk' })
vim.keymap.set('n', '<leader>gS', gitsigns.stage_buffer, { desc = 'Stage current buffer' })
vim.keymap.set('n', '<leader>gr', gitsigns.reset_hunk, { desc = 'Reset current hunk' })
vim.keymap.set('n', '<leader>gR', gitsigns.reset_buffer, { desc = 'Reset current buffer' })
vim.keymap.set('n', '<leader>h', gitsigns.next_hunk, { desc = 'Move to next hunk' })
vim.keymap.set('n', '<leader>H', gitsigns.prev_hunk, { desc = 'Move to previous hunk' })
vim.keymap.set('n', '<leader>ph', gitsigns.preview_hunk, { desc = 'Preview hunk in popup' })
+3
View File
@@ -0,0 +1,3 @@
require'indentmini'.setup()
vim.cmd.highlight('IndentLine guifg=#444444')
vim.cmd.highlight('IndentLineCurrent guifg=#557755')
+42
View File
@@ -0,0 +1,42 @@
-- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
if vim.v.shell_error ~= 0 then
vim.api.nvim_echo({
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
{ out, "WarningMsg" },
{ "\nPress any key to exit..." },
},
true, {})
vim.fn.getchar()
os.exit(1)
end
end
vim.opt.rtp:prepend(lazypath)
-- Make sure to setup `mapleader` and `maplocalleader` before
-- loading lazy.nvim so that mappings are correct.
-- This is also a good place to setup other settings (vim.opt)
vim.g.mapleader = " "
vim.g.maplocalleader = "\\"
-- Setup lazy.nvim
require("lazy").setup({
spec = {
-- import your plugins
{ import = "plugins" },
},
-- Configure any other settings here. See the documentation for more details.
-- colorscheme that will be used when installing plugins.
install = { colorscheme = { "habamax" } },
-- automatically check for plugin updates
checker = { enabled = true },
change_detection = { enabled = false }, -- active change detection seems to eat up memory over time https://github.com/folke/lazy.nvim/issues/1008
ui = {
border = "rounded",
},
})
-- Open lazy menu with :Lazy check
+41
View File
@@ -0,0 +1,41 @@
-- Reserve a space in the gutter
-- This will avoid an annoying layout shift in the screen
vim.opt.signcolumn = 'yes'
-- Add cmp_nvim_lsp capabilities settings to lspconfig
-- This should be executed before you configure any language server
local lspconfig_defaults = require('lspconfig').util.default_config
lspconfig_defaults.capabilities = vim.tbl_deep_extend(
'force',
lspconfig_defaults.capabilities,
require('cmp_nvim_lsp').default_capabilities()
)
require'lspconfig'.ts_ls.setup{}
-- This is where you enable features that only work
-- if there is a language server active in the file
vim.api.nvim_create_autocmd('LspAttach', {
desc = 'LSP actions',
callback = function(event)
local opts = {buffer = event.buf}
vim.keymap.set('n', 'K', '<cmd>lua vim.lsp.buf.hover()<cr>', opts)
vim.keymap.set('n', 'gd', '<cmd>lua vim.lsp.buf.definition()<cr>', opts)
vim.keymap.set('n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<cr>', opts)
vim.keymap.set('n', 'gi', '<cmd>lua vim.lsp.buf.implementation()<cr>', opts)
vim.keymap.set('n', 'go', '<cmd>lua vim.lsp.buf.type_definition()<cr>', opts)
vim.keymap.set('n', 'gr', '<cmd>lua vim.lsp.buf.references()<cr>', opts)
vim.keymap.set('n', 'gs', '<cmd>lua vim.lsp.buf.signature_help()<cr>', opts)
vim.keymap.set('n', '<F2>', '<cmd>lua vim.lsp.buf.rename()<cr>', opts)
vim.keymap.set({'n', 'x'}, '<F3>', '<cmd>lua vim.lsp.buf.format({async = true})<cr>', opts)
vim.keymap.set('n', '<F4>', '<cmd>lua vim.lsp.buf.code_action()<cr>', opts)
end,
})
-- helper plugin configuration
require'py_lsp'.setup{
host_python = '/usr/bin/python3',
default_venv_name = "venv",
language_server = "pylsp",
}
+11
View File
@@ -0,0 +1,11 @@
-- https://github.com/nvim-lualine/lualine.nvim
require('lualine').setup{
sections = {
lualine_c = {
{
'filename',
path = 1
}
}
}
}
+9
View File
@@ -0,0 +1,9 @@
require('mason').setup({})
require('mason-lspconfig').setup({
handlers = {
function(server_name)
require('lspconfig')[server_name].setup({})
end,
},
})
-- install language servers via :LspInstall
+25
View File
@@ -0,0 +1,25 @@
-- Custom remappings
-- paste buffer and dont replace buffer content with what has been pasted over (but put it to "void" buffer)
vim.keymap.set("x", "<leader>p", "\"_dP")
-- tab creation, navigation and closing
vim.keymap.set("n", "<C-t>", ":tabnew<CR>")
vim.keymap.set("n", "<C-h>", ":tabprevious<CR>")
vim.keymap.set("n", "<C-l>", ":tabnext<CR>")
vim.keymap.set("n", "<C-x>", ":tabclose<CR>")
-- resize windows with arrow keys
vim.keymap.set("n", "<Up>", ":resize -1<CR>")
vim.keymap.set("n", "<Down>", ":resize +1<CR>")
vim.keymap.set("n", "<Left>", ":vertical resize -1<CR>")
vim.keymap.set("n", "<Right>", ":vertical resize +1<CR>")
-- prompt user for command, run it and put it's output at cursor position
local function run_and_paste()
local out_raw = vim.fn.system(vim.fn.input('Command: '))
local out = string.gsub(out_raw, "\n", "")
local row, col = unpack(vim.api.nvim_win_get_cursor(0))
vim.api.nvim_buf_set_text(0, row - 1, col, row - 1, col, { out })
end
vim.keymap.set("n", "<C-c>", run_and_paste)
+22
View File
@@ -0,0 +1,22 @@
-- Custom settings
vim.opt.guicursor = ""
vim.opt.nu = true
vim.opt.relativenumber = true
vim.opt.scrolloff = 8
vim.opt.incsearch = true
vim.opt.signcolumn = "yes"
vim.o.termguicolors = true
vim.diagnostic.config({
virtual_text = true,
})
vim.opt.undofile = true
vim.o.winborder = 'rounded'
+32
View File
@@ -0,0 +1,32 @@
local builtin = require('telescope.builtin')
vim.keymap.set('n', '<leader>ff', builtin.find_files, { desc = 'Telescope find files' })
vim.keymap.set('n', '<leader>fg', builtin.live_grep, { desc = 'Telescope live grep' })
vim.keymap.set('n', '<leader>fb', builtin.buffers, { desc = 'Telescope buffers' })
vim.keymap.set('n', '<leader>fh', builtin.help_tags, { desc = 'Telescope help tags' })
vim.keymap.set('n', '<leader>ft', builtin.treesitter, { desc = 'Telescope treesitter picker' })
-- find selected text in visual mode with Ctrl-f via telescope:
vim.keymap.set('v', '<C-f>', 'y<ESC>:Telescope live_grep default_text=<C-r>0<CR>', default_opts)
-- grep hidden files as well
local telescopeConfig = require("telescope.config")
local vimgrep_arguments = { unpack(telescopeConfig.values.vimgrep_arguments) }
-- I want to search in hidden/dot files.
table.insert(vimgrep_arguments, "--hidden")
-- I don't want to search in the `.git` directory.
table.insert(vimgrep_arguments, "--glob")
table.insert(vimgrep_arguments, "!**/.git/*")
require('telescope').setup({
defaults = {
vimgrep_arguments = vimgrep_arguments,
layout_strategy = 'vertical',
layout_config = {
vertical = { width = 0.95 }
},
},
pickers = {
find_files = {
find_command = { "rg", "--files", "--hidden", "--glob", "!**/.git/*" },
},
},
})
@@ -0,0 +1,3 @@
require'treesitter-context'.setup{
enable = true,
}
+42
View File
@@ -0,0 +1,42 @@
require'nvim-treesitter.configs'.setup {
-- A list of parser names, or "all" (the listed parsers MUST always be installed)
ensure_installed = { "c", "lua", "vim", "vimdoc", "query", "markdown", "markdown_inline", "python", "javascript", "css", "html", "yaml", "java", "bash", "csv", "dockerfile", "htmldjango", "json", "nginx", "latex" },
-- Install parsers synchronously (only applied to `ensure_installed`)
sync_install = false,
-- Automatically install missing parsers when entering buffer
-- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally
auto_install = true,
-- List of parsers to ignore installing (or "all")
--ignore_install = { "javascript" },
highlight = {
enable = true,
-- NOTE: these are the names of the parsers and not the filetype. (for example if you want to
-- disable highlighting for the `tex` filetype, you need to include `latex` in this list as this is
-- the name of the parser)
-- list of language that will be disabled
--disable = { "c", "rust" },
-- Or use a function for more flexibility, e.g. to disable slow treesitter highlight for large files
--disable = function(lang, buf)
-- local max_filesize = 100 * 1024 -- 100 KB
-- local ok, stats = pcall(vim.loop.fs_stat, vim.api.nvim_buf_get_name(buf))
-- if ok and stats and stats.size > max_filesize then
-- return true
-- end
--end,
-- Setting this to true will run `:h syntax` and tree-sitter at the same time.
-- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).
-- Using this option may slow down your editor, and you may see some duplicate highlights.
-- Instead of true it can also be a list of languages
additional_vim_regex_highlighting = false,
},
-- indent with treesitter is currently experimental, just mark text and hit "="
indent = {
enable = true,
},
}
+3
View File
@@ -0,0 +1,3 @@
return {
{'neovim/nvim-cmp'}
}
+19
View File
@@ -0,0 +1,19 @@
return {
'cameron-wags/rainbow_csv.nvim',
config = true,
ft = {
'csv',
'tsv',
'csv_semicolon',
'csv_whitespace',
'csv_pipe',
'rfc_csv',
'rfc_semicolon'
},
cmd = {
'RainbowDelim',
'RainbowDelimSimple',
'RainbowDelimQuoted',
'RainbowMultiDelim'
}
}
+3
View File
@@ -0,0 +1,3 @@
return {
"sindrets/diffview.nvim"
}
+3
View File
@@ -0,0 +1,3 @@
return {
{'lewis6991/gitsigns.nvim', version='^1.0.2'}
}
+3
View File
@@ -0,0 +1,3 @@
return {
{'morhetz/gruvbox', config = function() vim.cmd.colorscheme("gruvbox") end }
}
+3
View File
@@ -0,0 +1,3 @@
return {
"nvimdev/indentmini.nvim",
}
+7
View File
@@ -0,0 +1,7 @@
return {
{'neovim/nvim-lspconfig', tag = 'v1.7.0'}, -- pin to a version thats compatible with nvim < 0.10
{'hrsh7th/cmp-nvim-lsp'},
{'hrsh7th/nvim-cmp'},
-- helper plugins
{'HallerPatrick/py_lsp.nvim'},
}
+4
View File
@@ -0,0 +1,4 @@
return {
'nvim-lualine/lualine.nvim',
dependencies = { 'nvim-tree/nvim-web-devicons' }
}
+7
View File
@@ -0,0 +1,7 @@
return {
-- pin version due to https://github.com/mason-org/mason.nvim/issues/1929
-- mason for downloading language servers
{'williamboman/mason.nvim', version = "^1.0.0"},
-- mason-lspconfig to configure auto setup of language servers
{'williamboman/mason-lspconfig.nvim', version = "^1.0.0"},
}
+9
View File
@@ -0,0 +1,9 @@
-- plugins form the "mini" plugin set https://github.com/echasnovski/mini.nvim?tab=readme-ov-file#modules
return {
-- auto-insert closing brackets etc.
{
'echasnovski/mini.pairs',
event = 'InsertEnter', -- lazy loading (when entering insert mode)
config = true, -- shorthand for calling plugins setup function
},
}
+4
View File
@@ -0,0 +1,4 @@
return {
"frankroeder/parrot.nvim",
dependencies = { "ibhagwan/fzf-lua", "nvim-lua/plenary.nvim" },
}
+6
View File
@@ -0,0 +1,6 @@
return {
"sgross-emlix/angerona.nvim",
dependencies = {
"nvim-lua/plenary.nvim",
},
}
+8
View File
@@ -0,0 +1,8 @@
return {
'nvim-telescope/telescope.nvim', tag = '0.1.8',
dependencies = {
'nvim-lua/plenary.nvim',
'BurntSushi/ripgrep', -- required for live_grep and grep_string and is the first priority for find_files
'nvim-telescope/telescope-fzf-native.nvim', -- native telescope sorter to significantly improve sorting performance
}
}
@@ -0,0 +1,4 @@
return {
{'nvim-treesitter/nvim-treesitter-context',
},
}
+6
View File
@@ -0,0 +1,6 @@
return {
{'nvim-treesitter/nvim-treesitter',
tag = 'v0.9.3'}, -- pin to a version that works with nvim < 0.10
-- configure parsers via config/treesitter.lua
-- update parsers with :TSUpdate
}
+6
View File
@@ -87,6 +87,12 @@ handle_extension() {
pandoc -s -t markdown -- "${FILE_PATH}" && exit 5 pandoc -s -t markdown -- "${FILE_PATH}" && exit 5
exit 1;; exit 1;;
## DOCX
docx)
## Uses: https://github.com/bgreenwell/doxx
doxx "${FILE_PATH}" && exit 5
exit 1;;
## XLSX ## XLSX
xlsx) xlsx)
## Preview as csv conversion ## Preview as csv conversion
+16
View File
@@ -1,8 +1,24 @@
set -g default-shell /usr/bin/zsh
# normal background for active pane
set-window-option -g window-active-style bg=terminal
# grayed background for inactive panes
set-window-option -g window-style bg="#32302f"
# ensure "autoread" works in nvim (auto reload files when changed)
set-option -g focus-events on
# https://gist.github.com/andersevenrud/015e61af2fd264371032763d4ed965b6
set -g default-terminal "tmux-256color"
set -ag terminal-overrides ",xterm-256color:RGB"
# List of plugins # List of plugins
set -g @plugin 'tmux-plugins/tmux-resurrect' set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum' set -g @plugin 'tmux-plugins/tmux-continuum'
# Plugin configurations
# auto-restore
set -g @continuum-restore 'on'
# Install plugin manager # Install plugin manager
#git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm #git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
# Install plugin: # Install plugin:
+43 -1
View File
@@ -21,6 +21,10 @@ checkcert()
{ {
openssl s_client -connect "$1":443 2>/dev/null openssl s_client -connect "$1":443 2>/dev/null
} }
pem2crt()
{
openssl x509 -inform PEM -in "$1" -out "${1%.*}.crt"
}
# works only without tex-ending # works only without tex-ending
tex2pdf() tex2pdf()
@@ -39,10 +43,12 @@ startx()
} }
# generate qrcode and display it # generate qrcode and display it
qrcode() func_qrcode()
{ {
qrencode "$1" -o - | feh - qrencode "$1" -o - | feh -
} }
# Create alias calling the function with space prefix, so that it is not logged in history file. This avoids logging passwords and stuff.
alias qrcode=" func_qrcode"
ogg2mp3() ogg2mp3()
{ {
@@ -57,6 +63,42 @@ m4a2mp3()
done done
} }
# Show all blob objects in repo sorted from smalles to largest
# https://stackoverflow.com/a/42544963
git-blobs()
{
git rev-list --objects --all --missing=print |
git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' |
sed -n 's/^blob //p' |
sort --numeric-sort --key=2 |
cut -c 1-12,41- |
$(command -v gnumfmt || echo numfmt) --field=2 --to=iec-i --suffix=B --padding=7 --round=nearest
}
# Do a short code review via several git commands
# https://piechowski.io/post/git-commands-before-reading-code/
git-review()
{
echo "### What Changes the Most (1y ago) ###"
git log --format=format: --name-only --since="1 year ago" | sort | uniq -c | sort -nr | head -20
echo "\n### Who Built This ###"
git --no-pager shortlog -sn --no-merges
echo "\n### Where Do Bugs Cluster ###"
git log -i -E --grep="fix|bug|broken" --name-only --format='' | sort | uniq -c | sort -nr | head -20
echo "\n### Is This Project Accelerating or Dying (commit count per m) ###"
git log --format='%ad' --date=format:'%Y-%m' | sort | uniq -c
echo "\n### How Often Is the Team Firefighting ###"
git log --oneline --since="1 year ago" | grep -iE 'revert|hotfix|emergency|rollback'
}
sshs()
{
tmprc=$(ssh $1 "mktemp --directory")
scp -q $HOME/.zshrc $1:$tmprc
ssh -t $1 "export ZDOTDIR=${tmprc}; trap 'rm -rf ${tmprc}' EXIT INT TERM; exec zsh"
#ssh $1 "rm -rf ${tmprc}"
}
# show the current mode: # show the current mode:
#PR_VIMODE="#" #PR_VIMODE="#"
#function zle-keymap-select #function zle-keymap-select
+4 -2
View File
@@ -82,6 +82,7 @@ source $ZSH/oh-my-zsh.sh
setopt appendhistory autocd extendedglob setopt appendhistory autocd extendedglob
setopt GLOB_COMPLETE setopt GLOB_COMPLETE
setopt HIST_IGNORE_SPACE # ignore command lines when first character is a space
unsetopt beep unsetopt beep
### Enter Vim-Mode ### ### Enter Vim-Mode ###
@@ -105,7 +106,7 @@ autoload -U promptinit
promptinit promptinit
export XDG_CONFIG_HOME=$HOME/.config/ export XDG_CONFIG_HOME=$HOME/.config/
export EDITOR=vim export EDITOR=nvim
alias ls='ls --color=always' alias ls='ls --color=always'
alias grep='grep --color=always' alias grep='grep --color=always'
@@ -113,6 +114,7 @@ alias less='less -R'
alias dd='dd status=progress oflag=direct' alias dd='dd status=progress oflag=direct'
alias dotfiles='git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME' alias dotfiles='git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'
alias hibernate='sudo systemctl hibernate' alias hibernate='sudo systemctl hibernate'
alias ssh="TERM=linux ssh" # for not complaining urxvt about terminals without TERM set #alias ssh="TERM=linux ssh" # for not complaining urxvt about terminals without TERM set
alias cpup="cp -T $0 ../$0" alias cpup="cp -T $0 ../$0"
alias pythonweb="python -m SimpleHTTPServer 8090" alias pythonweb="python -m SimpleHTTPServer 8090"
alias sayhi="echo hi"