Compare commits

...

16 commits

Author SHA1 Message Date
de462a270b
papis: Update options for new papis-bbt-formatter version 2025-06-09 14:38:16 +02:00
d91bc46d75
river: Add output quick switch script
Invoked by `MOD+SHIFT+O` (for '[O]utput'), it greps the kanshi
configuration file for existing profiles and allows you to select one
which kanshi tries to apply. Can be a little buggy, though due to kanshi
and not the plugin (sometimes failing to re-activate turned off screens
etc).
2025-06-09 14:38:15 +02:00
ff7863b011
river: Move hotkey for qute history to H
To prepare for output switch hotkey and since '[H]istory' makes more
sense, we switch it to `MOD+SHIFT+H`.
2025-06-09 14:38:15 +02:00
8dd268caf2
nvim: Allow registering lsp without providing configuration 2025-06-09 14:38:14 +02:00
de1591c7a7
nvim: Switch to maintained emmet lsp
Called 'emmet_language_server' instead of 'emmet_ls'.
2025-06-09 14:38:14 +02:00
7cc7195f9a
nvim: Update nushell lsp installation
Nushell lsp is now integrated directly into the 'nu' command. This
update stops mason from trying to install a 'nushell' LSP and simply
activates the nu-internal LSP if it finds the correct executable
instead.
2025-06-09 14:38:13 +02:00
3d1f925f78
nvim: Update mason-lspconfig for 2.0 2025-06-09 14:38:13 +02:00
63c6c81f6e
nvim: Fix ltex disabled autostart
Fixes #1ef7570.

We implement our own autostart-aware lsp register function. Any lsp
which has the option {autostart=false} set at their config root will be
not automatically enabled and can instead be enabled on demand.
2025-06-09 14:38:12 +02:00
6e6f804c08
repo: Format README 2025-06-09 14:38:11 +02:00
d8458ae010
nvim: Update checkbox markdown states
We now have the usual 'undone' ([ ]) and 'done' ([x]) states, but
express 3 further ones that are _somewhat_ standardized:

- [o] this one is 'doing', in-progress
- [-] this one is 'indeterminate', we're not sure
- [~] this one is 'deleted', never to be done
2025-06-09 14:38:11 +02:00
fad8f65214
nvim: Improve which-key group rendering
Moved most group definition functions into plugin 'init' functions so
they run at the beginning and are displayed more reliably.
2025-06-09 14:38:10 +02:00
4e7b64aad0
nvim: Add gitcommit and history extensions to codecompanion 2025-06-09 14:38:10 +02:00
1397fee17a
nvim: Enable fzf-lua integration for codecompanion
Since version 15.5.0 it supports showing selection menus with fzf-lua,
so we enable it here. Hardcoded for now.
2025-06-09 14:38:09 +02:00
19f3cd3457
nvim: Add copilot status to lualine 2025-06-09 14:38:09 +02:00
d3cdd0b30a
nvim: Fix llm models used by codecompanion 2025-06-09 14:38:08 +02:00
9efbcbfa01
nvim: Replace copilot.vim with copilot.lua
Makes the plugin less intrusive (will now only autocomplete on <M-p> or
<leader>ap). Can select suggestion with <M-]> or <M-[>, and accept with
<M-p> in-text or <CR> in-panel.

Still automatically started when invoking CodeCompanion chat.
2025-06-09 14:38:08 +02:00
13 changed files with 228 additions and 99 deletions

View file

@ -1,19 +1,19 @@
# `~/🌹`
Note that the below screenshots still show the X configuration from [v0.1](https://gitlab.com/marty-oehme/dotfiles/-/tags/v0.1) which is *very* old by now.
Note that the below screenshots still show the X configuration from [v0.1](https://gitlab.com/marty-oehme/dotfiles/-/tags/v0.1) which is _very_ old by now.
The current dotfiles are geared toward wayland for which the setup looks similar but not identical to the previews below.
## What's in these dotfiles
* [x] wayland setup using `riverwm` with quick access to many overlays and picking tools for styles, downloads, browsing history, passwords and more
* [x] vim configuration for simple programming tasks (especially python/bash/lua) and prose (markdown/quarto/latex)
* [x] academic workflow tools, to allow quick citation, pdf compilation, and preview
* [x] simple, efficient waybar with package update notification and mpris integration
* [x] system-wide color management (terminals, vim, qutebrowser, polybar, xresources) through [`flavours`](https://github.com/Misterio77/flavours) application using [base16](http://chriskempson.com/projects/base16/) themes
* [x] quick theme switching by activating `flavours` and fuzzy-searching themes with hot-key (default `<Super>=<Shift>+S`)
* [x] quick directory jumping using `z`, with `fzf` integration
* [x] `fzf`-like integrations for bibtex citation, vim buffer management, most recently used switching, shell command history, and more
* [x] password management with `pass` and picking it with automatic typing into any window
- [x] wayland setup using `riverwm` with quick access to many overlays and picking tools for styles, downloads, browsing history, passwords and more
- [x] vim configuration for simple programming tasks (especially python/bash/lua) and prose (markdown/quarto/latex)
- [x] academic workflow tools, to allow quick citation, pdf compilation, and preview
- [x] simple, efficient waybar with package update notification and mpris integration
- [x] system-wide color management (terminals, vim, qutebrowser, polybar, xresources) through [`flavours`](https://github.com/Misterio77/flavours) application using [base16](http://chriskempson.com/projects/base16/) themes
- [x] quick theme switching by activating `flavours` and fuzzy-searching themes with hot-key (default `<Super>=<Shift>+S`)
- [x] quick directory jumping using `z`, with `fzf` integration
- [x] `fzf`-like integrations for bibtex citation, vim buffer management, most recently used switching, shell command history, and more
- [x] password management with `pass` and picking it with automatic typing into any window
[![Styler recoloring demo](https://gitlab.com/marty-oehme/dotfiles/-/wikis/uploads/bde87deda694590a2e08e21552e11309/styler.webp)](https://gitlab.com/marty-oehme/dotfiles/-/wikis/uploads/90894e53eff378db4d7f9f49e7a69fab/styler.mp4)
@ -25,19 +25,20 @@ I would recommend doing an initial `git clone --recursive` for this repository,
Of course, you can do it non-recursively and then just pull those modules selectively which you actually want.
Once in the repository directory, when you then run `./install.sh` it will install many of the packages I use (though they are probably slightly out-of-date) and link the dotfiles into the home directory.
I would mostly recommend this on fresh machines or a test machine first - it *will* link my personal dotfiles and, if you allow it, *will* install quite a few packages.
I would mostly recommend this on fresh machines or a test machine first - it _will_ link my personal dotfiles and, if you allow it, _will_ install quite a few packages.
By default it will ask your consent for some steps -- use `./install.sh -f` to force yes to everything.
The dotfile installation procedure is based on `dotter`, it will generally *not overwrite* anything already in the home directory, but of course be observant when doing ptentially destructive operations.
The dotfile installation procedure is based on `dotter`, it will generally _not overwrite_ anything already in the home directory, but of course be observant when doing ptentially destructive operations.
> **NOTE**
> The same non-destructive installation procedure does *not* apply to the package installation and system setting file linking, where it can potentially overwrite or remove existing files.
> The same non-destructive installation procedure does _not_ apply to the package installation and system setting file linking, where it can potentially overwrite or remove existing files.
After all files are linked and you open a new shell session, the `dotlink` alias will allow you to re-link all dotfiles from anywhere on the system.[^1]
[^1]: This alias only works when the dotfiles are cloned into `~/.dotfiles`, mirroring my setup.
[^1]:
This alias only works when the dotfiles are cloned into `~/.dotfiles`, mirroring my setup.
This is due to a hard-coded cd into this directory.
If your dotfiles lie in another directory and you want to use the dotlink alias, simply change the corresponding line in `bootstrap/.config/sh/alias.d/dotlink.sh`
If your dotfiles lie in another directory, and you want to use the dotlink alias, simply change the corresponding line in `bootstrap/.config/sh/alias.d/dotlink.sh`
Both automatic installation paths are presumably somewhat brittle. In any case, I would suggest to manually look through the files for things you want instead of copying and activating everything.
Dotfiles are too personal to be standardized like that.
@ -48,29 +49,30 @@ Enjoy!
![Overview - an older image of the dotfile desktop with gaps, showing git logs, styler logs, duckduckgo in a browser, and a vifm view of the dotfiles themselves](https://gitlab.com/marty-oehme/dotfiles/-/wikis/uploads/aaf0319d575dc192ea0f4bd6eaf83c08/gaps.png)
* [`wayland`](https://github.com/wayland-project/wayland) - Containing basics for fully functional tiling wayland setup:
* [`river`](https://github.com/riverwm/river) - Tiling window manager for wayland
* [`waybar`](https://github.com/Alexays/Waybar) - Easily customizable statusbar for wayland
* [`bemenu`](https://github.com/Cloudef/bemenu) - Extended dmenu replacement for wayland, X11 and ncurses
* [`fontconfig`] - System-wide font replacements and styling settings
* [`wezterm`](https://wezfurlong.org/wezterm/) - Terminal emulator and multiplexer (fast, understandable and lua configurable)
* [`nvim`](https://neovim.io/) - Neovim configuration
* [`vifm`](https://github.com/vifm/vifm) - vim-like file-manager
* [`qutebrowser`](https://github.com/qutebrowser/qutebrowser) - vim-key enabled web browser
* [`pass`](pass/README.md) - Password management suite
* [`bibtex`] - LateX/BibteX/pandoc plaintext writing & reference suite (slowly migrating toward [typst](https://typst.app))
* [`git`](git/README.md) - distributed version control system.
* [`office`](office/README.md) - office/productivity software for writing e-mail and setting appointments
- [`wayland`](https://github.com/wayland-project/wayland) - Containing basics for fully functional tiling wayland setup:
- [`river`](https://github.com/riverwm/river) - Tiling window manager for wayland
- [`waybar`](https://github.com/Alexays/Waybar) - Easily customizable statusbar for wayland
- [`bemenu`](https://github.com/Cloudef/bemenu) - Extended dmenu replacement for wayland, X11 and ncurses
- [`fontconfig`] - System-wide font replacements and styling settings
- [`wezterm`](https://wezfurlong.org/wezterm/) - Terminal emulator and multiplexer (fast, understandable and lua configurable)
- [`nvim`](https://neovim.io/) - Neovim configuration
- [`vifm`](https://github.com/vifm/vifm) - vim-like file-manager
- [`qutebrowser`](https://github.com/qutebrowser/qutebrowser) - vim-key enabled web browser
- [`pass`](pass/README.md) - Password management suite
- [`typst`] - LateX/BibteX/pandoc-like plaintext writing & reference suite
- [`jujutsu`](vcs/README.md) - distributed version control system, together with git.
- [`office`](office/README.md) - office/productivity software for writing e-mail and setting appointments
## Notes
* Generally, most configuration for applications attempts to follow the XDG specifications, keeping configuration in .config directory and supplementary files in .local/share directory. Over time, I am moving more applications to this standard: it keeps the home directory clean, and the separation of configuration, binaries, and data relatively clear.
* The `zsh` directory contains all setup for the z-shell, my daily work environment. It should not be required for working with any other module but will add additional functionality to many (such as command auto-completion and so on). `sh` sets some base functionality for any shell you may wish to work in. It is, for now, the only module that is required for some other modules to work.[^shreq]
* `rofi` contains additional scripts and a simple theming framework for rofi and should probably be reorganized to put the correct files into the correct directories (per xdg) at some point.
* Whereas `sh` module scripts are requirements for other scripts, `.local/bin` in the `scripts` module contains most executable user scripts. Most of these have been migrated to other corresponding modules (e.g. if a script exclusively targets git functionality, it will live there), some useful --- or left-over --- stand-alone scripts remain however.
* `.local/share/pandoc` contains configuration for academic latex writing (pandoc, really) and is of interest if you want to use this functionality.
* `.xinitrc` is used for x initialization and program startup. At some point, some of the consistently running applications may be moved to systemd/runit as supervised services.
* Generally, top-level directories starting with a . are only meaningful for the *repository* not for the functionality of the machine that these dotfiles are deployed on. That means `.gitlab-ci.yml`, `.assets/`, `.gitignore` and similar files and directories will not show up in the final deployment in any home directory. Perhaps they should be called dotdot-files since they're the dotfiles for my dotfiles. 🙂 (Also, '[dotfiles](https://en.wikipedia.org/wiki/Semantic_satiation)'.)
- This are a good sign.
- Generally, most configuration for applications attempts to follow the XDG specifications, keeping configuration in .config directory and supplementary files in .local/share directory. Over time, I am moving more applications to this standard: it keeps the home directory clean, and the separation of configuration, binaries, and data relatively clear.
- The `zsh` directory contains all setup for the z-shell, my daily work environment. It should not be required for working with any other module but will add additional functionality to many (such as command auto-completion and so on). `sh` sets some base functionality for any shell you may wish to work in. It is, for now, the only module that is required for some other modules to work.[^shreq]
- `rofi` contains additional scripts and a simple theming framework for rofi and should probably be reorganized to put the correct files into the correct directories (per xdg) at some point.
- Whereas `sh` module scripts are requirements for other scripts, `.local/bin` in the `scripts` module contains most executable user scripts. Most of these have been migrated to other corresponding modules (e.g. if a script exclusively targets git functionality, it will live there), some useful --- or left-over --- stand-alone scripts remain however.
- `.local/share/pandoc` contains configuration for academic latex writing (pandoc, really) and is of interest if you want to use this functionality.
- `.xinitrc` is used for x initialization and program startup. At some point, some of the consistently running applications may be moved to systemd/runit as supervised services.
- Generally, top-level directories starting with a . are only meaningful for the _repository_ not for the functionality of the machine that these dotfiles are deployed on. That means `.gitlab-ci.yml`, `.assets/`, `.gitignore` and similar files and directories will not show up in the final deployment in any home directory. Perhaps they should be called dotdot-files since they're the dotfiles for my dotfiles. 🙂 (Also, '[dotfiles](https://en.wikipedia.org/wiki/Semantic_satiation)'.)
[^shreq]: I may remove this requirement in the future to make modules more self-contained. However, relying on some base utility scripts makes it easier to avoid duplicating such functionality for each individual script in other modules.

View file

@ -5,13 +5,6 @@ profile docked {
exec notify-send "💻 Display changed" "Applying docked LG profile"
}
profile docked {
output "Goldstar Company Ltd W2442 0x000574FD" position 1920,0
output "Goldstar Company Ltd W2442 0x000574E1" position 0,0
output eDP-1 disable
exec notify-send "💻 Display changed" "Applying docked Goldstar profile"
}
profile dockedall {
output "LG Electronics W2442 0x000574FD" position 1920,0
output "LG Electronics W2442 0x000574E1" position 0,0
@ -19,7 +12,7 @@ profile dockedall {
exec notify-send "💻 Display changed" "Applying docked 3-screen profile"
}
profile portable {
profile portableforce {
output "LG Electronics W2442 0x000574FD" disable
output "LG Electronics W2442 0x000574E1" disable
output eDP-1 enable position 0,0

View file

@ -98,7 +98,7 @@ riverctl map normal $mod backspace spawn "powermenu"
# Open Bookmark search
riverctl map normal None XF86Search spawn "qutedmenu"
riverctl map normal $mod+Shift O spawn "qutedmenu"
riverctl map normal $mod+Shift H spawn "qutedmenu"
# Clipboard history
riverctl map normal $mod+Shift Space spawn "clipman pick --tool=bemenu"
@ -176,6 +176,7 @@ riverctl map normal $mod+Shift v toggle-float
# shellcheck disable=SC2016
# Make all connected outputs show the desktop and no windows at all
riverctl map normal $mod+Shift M spawn 'for i in $(wlopm | wc -l); do riverctl set-focused-tags $((1 << 10)); riverctl focus-output next; done; riverctl set-focused-tags $((1 << 10)); riverctl focus-output next'
riverctl map normal $mod+Shift O spawn "kanshiswitch"
riverctl map normal $mod+Shift F10 spawn "riverctl send-layout-cmd $layout_cmd '--tags all --output all view-padding 0'"
riverctl map normal $mod F10 spawn "riverctl send-layout-cmd $layout_cmd '--tags all --output all view-padding 6'"
@ -306,7 +307,6 @@ for pad in $(riverctl list-inputs | grep -i touchscreen); do
riverctl input "$pad" pointer-accel 0.5
done
# We are not in voidlinux, so no nice turnstile user services will take care of us
# have to start everything manually here.
if ! cat /etc/*-release | grep -q '^NAME=.*Void'; then

29
desktop/.local/bin/kanshiswitch Executable file
View file

@ -0,0 +1,29 @@
#!/usr/bin/env sh
if ! exist kanshictl; then
printf "Requires command 'kanshictl' on system."
exit 1
fi
picker=dmenu
if exist bemenu; then
picker=bemenu
elif exist wofi; then
picker=wofi
elif exist rofi; then
picker=rofi
fi
regex='s/profile \+\(.*\) \+{/\1/p'
list=$(sed -ne "$regex" "${XDG_CONFIG_HOME:-~/.config}/kanshi/config")
profile=$(printf "%s" "$list" | "$picker")
if [ -z "$profile" ]; then
return
else
kanshictl switch "$profile"
fi
if [ "$1" = '-v' ]; then
notify-send "Kanshi profile set" "Set to: $profile"
fi

View file

@ -8,9 +8,12 @@
"cmp-calc": { "branch": "main", "commit": "5947b412da67306c5b68698a02a846760059be2e" },
"cmp-pandoc.nvim": { "branch": "main", "commit": "30faa4456a7643c4cb02d8fa18438fd484ed7602" },
"cmp-spell": { "branch": "master", "commit": "694a4e50809d6d645c1ea29015dad0c293f019d6" },
"codecompanion.nvim": { "branch": "main", "commit": "73bac3b52d9b7f52e89ac6698dd7df8962f0454c" },
"codecompanion-gitcommit.nvim": { "branch": "main", "commit": "28f05d8e28f1abae4a333f761944119d4080e6ee" },
"codecompanion-history.nvim": { "branch": "main", "commit": "66943e78bcacaa27f4ac4a398df4016eb5413ecd" },
"codecompanion.nvim": { "branch": "main", "commit": "ecf07d4a914f44455b5098acd49746b8dc5375f0" },
"conform.nvim": { "branch": "master", "commit": "a6f5bdb78caa305496357d17e962bbc4c0b392e2" },
"copilot.vim": { "branch": "release", "commit": "7167958954532a0a1b83f2db2f591b43aebff44c" },
"copilot-lualine": { "branch": "main", "commit": "6bc29ba1fcf8f0f9ba1f0eacec2f178d9be49333" },
"copilot.lua": { "branch": "master", "commit": "c1bb86abbed1a52a11ab3944ef00c8410520543d" },
"dial.nvim": { "branch": "master", "commit": "2c7e2750372918f072a20f3cf754d845e143d7c9" },
"dressing.nvim": { "branch": "master", "commit": "3a45525bb182730fe462325c99395529308f431e" },
"fidget.nvim": { "branch": "main", "commit": "b61e8af9b8b68ee0ec7da5fb7a8c203aae854f2e" },

View file

@ -7,9 +7,12 @@
-- with their respective names used by lspconfig, nvim-treesitter, nvim-lint and conform.
--
local nushell = { lsp = { nushell = {} }, ts = { "nu" } }
if vim.fn.executable("nufmt") == 1 then
nushell.format = { nu = { "nufmt" } }
local nushell = function()
local nushell = { ts = { "nu" } } -- nushell lsp directly built into `nu` cmd
if vim.fn.executable("nufmt") == 1 then
nushell.format = { nu = { "nufmt" } }
end
return nushell
end
-- FIXME: This does not work for populating LSP config,
@ -52,7 +55,7 @@ local languages = {
docker_compose = { lsp = { docker_compose_language_service = {} } },
docker = { lsp = { dockerls = {} }, ts = { "dockerfile" } },
dot = { ts = { "dot" } },
emmet = { lsp = { emmet_ls = {} } },
emmet = { lsp = { emmet_language_server = {} } },
javascript = {
lsp = { eslint = {} },
ts = { "javascript" },
@ -71,7 +74,7 @@ local languages = {
},
latex = {
-- TODO: May need to switch to ltex_plus at some point since ltex is unmaintained
lsp = { ltex = { autostart = false }, texlab = {} },
lsp = { ltex = { disable = true }, texlab = {} },
ts = { "latex" },
},
lua = {
@ -96,7 +99,7 @@ local languages = {
format = { markdown = { "prettier", "injected" } },
},
nim = { lsp = { nim_langserver = {} }, ts = { "nim", "nim_format_string" }, format = { nim = { "nimpretty" } } },
nu = nushell,
nu = nushell(),
python = {
lsp = { basedpyright = {}, ruff = {} },
ts = { "python" },

View file

@ -1,11 +1,38 @@
return {
{
-- NOTE: Requires manual auth with ':Copilot auth' or 'GH_COPILOT_TOKEN' set as envvar
"zbirenbaum/copilot.lua",
dependencies = { "AndreM222/copilot-lualine" },
cmd = "Copilot",
event = "InsertEnter",
opts = {
panel = { layout = { position = "bottom" } },
suggestion = { keymap = { accept = "<M-p>" } },
},
keys = {
{
"<leader>ap",
function()
-- FIXME: If opening before lazy-loaded, errors
require("copilot.panel").open({})
require("copilot.panel").refresh()
end,
desc = "Refresh Copilot Panel",
silent = true,
mode = { "n" },
},
},
},
-- TODO: Add completion w blink, see https://codecompanion.olimorris.dev/installation.html
{
"olimorris/codecompanion.nvim",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-treesitter/nvim-treesitter",
"github/copilot.vim",
"zbirenbaum/copilot.lua",
{ "ibhagwan/fzf-lua", optional = true },
"ravitemer/codecompanion-history.nvim",
"jinzhongjia/codecompanion-gitcommit.nvim",
},
init = function(_)
if require("core.util").is_available("which-key") then
@ -30,7 +57,8 @@ return {
default = "llama-3.1-8b-instant",
choices = {
"llama-3.3-70b-versatile",
"mixtral-8x7b-32768",
"meta-llama/llama-4-maverick-17b-128e-instruct",
"mistral-saba-24b",
},
},
},
@ -43,6 +71,31 @@ return {
})
end,
},
display = {
action_palette = {
provider = "fzf_lua",
},
},
extensions = {
history = {
enabled = true,
auto_save = false,
expiration_days = 7,
picker = "fzf-lua",
delete_on_clearing_chat = true,
},
gitcommit = {
enabled = true,
callback = "codecompanion._extensions.gitcommit",
opts = {
add_slash_command = true,
buffer = {
enabled = true,
keymap = "<leader>ag",
},
},
},
},
},
keys = {
{ "<leader>aa", "<cmd>CodeCompanionActions<cr>", desc = "Actions", silent = true, mode = { "n", "v" } },

View file

@ -23,7 +23,21 @@ local lsp = {
dependencies = {
{
"williamboman/mason-lspconfig.nvim",
opts = { automatic_installation = true },
opts = function()
local to_install = {}
local not_enabled = {}
for k, v in pairs(get_all_servers()) do
table.insert(to_install, k)
if v["disable"] and v["disable"] == true then
table.insert(not_enabled, k)
end
end
local tbl = {
ensure_installed = to_install,
automatic_enable = { exclude = not_enabled },
}
return tbl
end,
dependencies = { "williamboman/mason.nvim" },
cmd = { "LspInstall", "LspUninstall" },
},
@ -31,6 +45,11 @@ local lsp = {
},
event = { "BufReadPost", "BufNewFile", "BufWritePre" },
opts = { servers = get_all_servers() },
init = function()
if require("core.util").is_available("which-key") then
require("which-key").add({ "<localleader>l", group = "language" })
end
end,
config = function(_, lspconfig_opts)
-- Display diagnostics as virtual text only if not in insert mode
-- /r/neovim/comments/12inp4c/disable_diagnostics_virtual_text_when_in_insert/jqqifwk/
@ -51,19 +70,21 @@ local lsp = {
vim.fn.sign_define("DiagnosticSignInfo", { text = "", texthl = "DiagnosticSignInfo" })
vim.fn.sign_define("DiagnosticSignHint", { text = "", texthl = "DiagnosticSignHint" })
local function register(server_name, config)
local function register(server_name, config, enabled)
if vim.fn.has("nvim-0.11") == 1 then
vim.lsp.config(server_name, config)
vim.lsp.config(server_name, config or {})
if enabled == false or vim.lsp.config[server_name]["autostart"] == false then
vim.lsp.enable(server_name, false)
else
vim.lsp.enable(server_name, true)
end
else
require("lspconfig")[server_name].setup(config)
end
end
for server_name, config in pairs(lspconfig_opts.servers) do
register(server_name, config)
if vim.fn.has("nvim-0.11") == 0 then
config.capabilities = require("blink.cmp").get_lsp_capabilities(config.capabilities)
end
if vim.fn.executable("nu") == 1 then
register("nushell")
end
register("marksman", {
@ -181,19 +202,28 @@ local lsp = {
vim.api.nvim_create_autocmd("User", {
pattern = "SpellEnable",
callback = function()
register("ltex", {
on_attach = function(_, _)
if require("core.util").is_available("ltex_extra") then
require("ltex_extra").setup()
end
end,
settings = {
ltex = {
language = vim.o.spelllang,
},
},
local mapped = {}
local lang_map = {
en_us = "en-US",
en_gb = "en-GB",
de_de = "de-DE",
}
for _, v in ipairs(vim.opt.spelllang:get()) do
table.insert(mapped, lang_map[v])
end
vim.lsp.config("ltex", {
settings = { ltex = { language = mapped } },
})
vim.cmd("LspStart ltex")
-- single-shot setup: Enable for this buffer
-- but instantly disable again globally
vim.lsp.enable("ltex")
vim.lsp.enable("ltex", false)
end,
})
vim.api.nvim_create_autocmd("User", {
pattern = "SpellDisable",
callback = function()
vim.lsp.enable("ltex", false)
end,
})
end,
@ -225,9 +255,6 @@ vim.api.nvim_create_autocmd("LspAttach", {
o({ desc = "Next error" })
)
if require("core.util").is_available("which-key") then
require("which-key").add({ "<localleader>l", group = "language" })
end
map("n", "<localleader>ld", "<cmd>lua vim.diagnostic.open_float()<cr>", o({ desc = "Show line diagnostics" }))
map("n", "<localleader>la", "<cmd>lua vim.lsp.buf.code_action()<cr>", o({ desc = "Codeactions" }))
map("n", "<localleader>ln", "<cmd>lua vim.lsp.buf.rename()<cr>", o({ desc = "Rename element" }))

View file

@ -80,8 +80,9 @@ local prose_plugs = {
},
checkbox = {
custom = {
todo = { raw = "[-]", rendered = "󰡖 ", highlight = "RenderMarkdownTodo" },
removed = { raw = "[_]", rendered = "󱋭 ", highlight = "RenderMarkdownTodo" },
doing = { raw = "[o]", rendered = "󰡖 ", highlight = "RenderMarkdownTodo" },
indeterminate = { raw = "[-]", rendered = "󰄗 ", highlight = "RenderMarkdownTodo" },
removed = { raw = "[~]", rendered = "󱋭 ", highlight = "RenderMarkdownTodo" },
},
},
html = {
@ -97,6 +98,11 @@ local prose_plugs = {
},
ft = md_like,
cmd = "RenderMarkdown",
init = function()
if require("core.util").is_available("which-key") then
require("which-key").add({ { "<localleader>p", group = "presentation" } })
end
end,
keys = {
{
"<localleader>pm",
@ -160,6 +166,11 @@ local prose_plugs = {
},
},
cmd = { "PasteImage" },
init = function()
if require("core.util").is_available("which-key") then
require("which-key").add({ { "<localleader>p", group = "presentation" } })
end
end,
keys = {
{ "<localleader>pp", "<cmd>PasteImage<cr>", desc = "Paste image from system clipboard" },
},
@ -169,7 +180,7 @@ local prose_plugs = {
-- bring zettelkasten commands
{
"zk-org/zk-nvim",
config = function()
init = function()
if require("core.util").is_available("which-key") then
require("which-key").add({
{ "<leader>n", group = "notes" },
@ -177,7 +188,8 @@ local prose_plugs = {
{ "<localleader>n", group = "note", mode = "v" },
})
end
end,
config = function()
require("zk.commands").add("ZkOrphans", function(opts)
opts = vim.tbl_extend("force", { orphan = true }, opts or {})
require("zk").edit(opts, { title = "Zk Orphans" })

View file

@ -16,7 +16,7 @@ return {
return ""
elseif has_pynvim == 1 then
if molten_ft[vim.bo.filetype] == nil then
return ""
return ""
end
local status_ok, res = pcall(function()
return require("molten.status").kernels() ~= ""
@ -60,7 +60,13 @@ return {
lualine_a = { "mode" },
lualine_b = { "branch", "diff", "diagnostics" },
lualine_c = { "filename" },
lualine_x = { "encoding", "fileformat", "filetype", molten },
lualine_x = {
"encoding",
{ "copilot", symbols = { status = { icons = { unknown = "", enabled = "" } } } },
"fileformat",
"filetype",
molten,
},
lualine_y = { "progress" },
lualine_z = { selectionCount, "location" },
},

View file

@ -32,6 +32,11 @@ return {
"nvim-neotest/neotest-python",
},
init = function()
if require("core.util").is_available("which-key") then
require("which-key").add({ "<localleader>t", group = "test" })
end
end,
config = function()
require("neotest").setup({
adapters = {
@ -41,9 +46,6 @@ return {
}),
},
})
if require("core.util").is_available("which-key") then
require("which-key").add({ "<localleader>t", group = "test" })
end
end,
ft = { "python" },
keys = {

View file

@ -3,18 +3,17 @@
The bare minimum terminal configuration for a working system.
Contains:
* an XDG compliant home directory setup
* several basic environment variables
* simple aliases
* an optional fzf default setup
* X autostart
- an XDG compliant home directory setup
- several basic environment variables
- simple aliases
- an optional fzf default setup
- X autostart
While other modules are largely optional,
While other modules are largely optional,
this module is the only one strictly necessary for the system to really work at all.
Additionally contains two scripts on which some other modules build:
* a simple script to detect if applications exist
- a simple script to detect if applications exist
(and optionally warn the user if they don't)
* and a script to check if internet connectivity exists
- and a script to check if internet connectivity exists

View file

@ -11,8 +11,8 @@ file-browser = vifm
# edit info.yaml as new papers are added
add-edit = True
# ref-format = {doc[author_list][0][family]}{doc[year]}
ref-format = bbt
add-folder-name = {doc[author_list][0][family]}-{doc[title]}
ref-format = bbt:
add-folder-name = {doc[author_list][0][family]}-{doc[title]} # NOTE: Has issues if no author list
add-file-name = {doc[author_list][0][family]}{doc[year]}
header-format-file = ~/.config/papis/headerformat
extra-bibtex-keys = ["tags", "readstatus", "priority"]
@ -68,7 +68,7 @@ dir = ~/documents/library/academia
[plugins.extract]
tags = {"red": "important", "green": "extra", "blue": "toread"}
[plugins.bbt-formatter]
[plugins.bbt]
full-year = True
title-words = 2
title-chars = 20