Compare commits

..

3 commits

Author SHA1 Message Date
ff3656deb7
Commit message:
- Update `conform.nix` to configure notifyOnError and add keymaps for conform.nvim.
- Remove deprecated format_on_save settings.
- Add new key mappings for formatting with conform.nvim.
2025-02-19 23:47:16 +08:00
3d0b34c714
feat: remove unused keymap and simplify whichkey configuration 2025-02-19 23:45:51 +08:00
10151c17a8
chore: update telescope keymap descriptions and file picker key
- Change file picker key from "<leader>ff" to "<leader>sf".
- Update description in telescope config for better clarity.
- No functional change, just a documentation improvement.
2025-02-19 23:44:44 +08:00
3 changed files with 23 additions and 21 deletions

View file

@ -7,14 +7,6 @@
enable = true;
settings = {
# Run the formatter on file save.
format_on_save = {
lspFallback = true;
timeoutMs = 500;
};
# Receive notificaton when a formatter errors.
notifyOnError = true;
# Map of filetype to formatters.
formatters_by_ft = {
c = ["clang-format"];
@ -34,6 +26,25 @@
command = lib.getExe pkgs.stylua;
};
};
# Receive notificaton when a formatter errors.
notifyOnError = true;
};
};
# Keymaps for conform.nvim
keymaps = [
{
mode = "";
key = "<leader>f";
action.__raw = ''
function()
require('conform').format { async = true, lsp_fallback = true }
end
'';
options = {
desc = "Format buffer";
};
}
];
}

View file

@ -18,10 +18,10 @@
# Configure our telescope keymaps.
keymaps = {
# File Pickers
"<leader>ff" = {
"<leader>sf" = {
action = "find_files";
options = {
desc = "Find project files";
desc = "Search project files";
};
};
"<leader>/" = {
@ -32,10 +32,10 @@
};
# Vim Pickers
"<leader>fb" = {
"<leader>sb" = {
action = "buffers";
options = {
desc = "Find open buffers";
desc = "Search open buffers";
};
};
"<leader>:" = {

View file

@ -5,15 +5,6 @@
# Prefixes, No operation.
keymaps = [
{
mode = "n";
key = "<leader>f";
action = "<Nop>";
options = {
desc = "+find/files";
};
}
{
mode = "n";
key = "<leader>s";