(desktop) Gen 494: disabled auto linebreak by default in nixvim, made it only activate in plain text files like .md or .txt where linebreak formatting actually matters
This commit is contained in:
@@ -4,21 +4,31 @@
|
||||
command = "FloatermNew --wintype=float --name=shadeterm --position=topright --autoclose=0 --silent --cwd=<buffer> --titleposition=left zsh";
|
||||
event = ["VimEnter"];
|
||||
pattern = ["*"];
|
||||
desc = "Create a floating terminal, placed in the top right";
|
||||
}
|
||||
{
|
||||
command = "silent! mkview";
|
||||
event = ["BufWinLeave"];
|
||||
pattern = ["*"];
|
||||
desc = "Save session window settings to be loaded next time the file is opened";
|
||||
}
|
||||
{
|
||||
command = "silent! !aplay ~/sound/sys/cd.wav > /dev/null 2>&1 &";
|
||||
event = ["BufWinLeave"];
|
||||
pattern = ["*"];
|
||||
desc = "Play a neat little sound effect when you close neovim";
|
||||
}
|
||||
{
|
||||
command = "silent! loadview";
|
||||
event = ["BufWinEnter"];
|
||||
pattern = ["*"];
|
||||
desc = "Load previous session window settings for the opened file (folds, cursor pos, etc)";
|
||||
}
|
||||
{
|
||||
command = "setlocal textwidth = 135";
|
||||
event = ["BufWinEnter" "BufEnter"];
|
||||
pattern = ["*.md" "*.wiki" "*.txt"];
|
||||
desc = "Set automatic linebreaks in plain text file formats";
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
vim.opt.relativenumber = true
|
||||
vim.opt.hlsearch = true
|
||||
vim.opt.incsearch = true
|
||||
vim.opt.shiftwidth = 4
|
||||
vim.opt.tabstop = 4
|
||||
vim.opt.shiftwidth = 2
|
||||
vim.opt.tabstop = 2
|
||||
vim.opt.termguicolors = true
|
||||
vim.opt.ruler = true
|
||||
vim.opt.scrolloff = 6
|
||||
@@ -33,7 +33,7 @@
|
||||
vim.opt.foldmethod = "manual"
|
||||
vim.opt.wrap = true
|
||||
vim.opt.linebreak = true
|
||||
vim.opt.textwidth = 135
|
||||
vim.opt.textwidth = 0
|
||||
vim.opt.breakat = " \t!@*-+;:,./?"
|
||||
|
||||
vim.g.mapleader = "!"
|
||||
|
||||
Reference in New Issue
Block a user