aboutsummaryrefslogtreecommitdiffstats
path: root/home-manager/soispha/config/neovim/nixvim/autocmds
diff options
context:
space:
mode:
authorSoispha <soispha@vhack.eu>2023-08-19 20:36:54 +0200
committerSoispha <soispha@vhack.eu>2023-08-19 20:36:54 +0200
commit926ffc9c04613d0a60c46d0fc417244dc318817d (patch)
tree9181277612467ef82e22d4ccbdaa57be7fbc8f83 /home-manager/soispha/config/neovim/nixvim/autocmds
parentFix(hm/conf/neovim): Remove duplicate mapping, which mapped n to n (diff)
downloadnixos-config-926ffc9c04613d0a60c46d0fc417244dc318817d.zip
Fix(hm/conf/neovim/autocmds): Add anchor to space replacement
Without this the following code would be completely minimized: ``` {...}:{ services.lua_language={ enable=true; }; } ``` → ``` {...}:{ services.lua_language={ enable=true; }; } ```. Now it should only strip the whitespace at the end of the lines.
Diffstat (limited to 'home-manager/soispha/config/neovim/nixvim/autocmds')
-rw-r--r--home-manager/soispha/config/neovim/nixvim/autocmds/default.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/home-manager/soispha/config/neovim/nixvim/autocmds/default.nix b/home-manager/soispha/config/neovim/nixvim/autocmds/default.nix
index c2b64ae3..b1945944 100644
--- a/home-manager/soispha/config/neovim/nixvim/autocmds/default.nix
+++ b/home-manager/soispha/config/neovim/nixvim/autocmds/default.nix
@@ -10,7 +10,7 @@
event = ["BufWritePre"];
pattern = ["*"];
command = ''
- ks | if search("\\s\\+$", 'n') != 0 | :%s/\s\+//g | endif | 's
+ ks | if search("\\s\\+$", 'n') != 0 | :%s/\s\+$// | endif | 's
'';
description = ''
Remove trailing whitespace on safe