diff --git a/README.md b/README.md index fdb6a0b..d9ca2ef 100644 --- a/README.md +++ b/README.md @@ -93,7 +93,7 @@ I won't provide links for each of these plugins as they are easily to be found. - `autopairs.nvim`. - `Comment.nvim` to comment lines and blocs. - `ident-blankline.nvim` to improve readability of indentation. -- `true-zen.nvim` for a good zen mode. +- `zen-mode.nvim` for a good zen mode. - `toggleterm.nvim` to quickly get a terminal. Might find a better one. - `rainbow-csv.nvim` to manage CSV files. - `venv-selector.nvim` to ease python virtual env. diff --git a/lua/plugins/true-zen.lua b/lua/plugins/true-zen.lua deleted file mode 100644 index ce6a343..0000000 --- a/lua/plugins/true-zen.lua +++ /dev/null @@ -1,35 +0,0 @@ -local api = vim.api - -api.nvim_set_keymap("n", "zn", ":TZNarrow", {}) -api.nvim_set_keymap("v", "zn", ":'<,'>TZNarrow", {}) -api.nvim_set_keymap("n", "zf", ":TZFocus", {}) -api.nvim_set_keymap("n", "zm", ":TZMinimalist", {}) -api.nvim_set_keymap("n", "za", ":TZAtaraxis", {}) - -return { - "Pocco81/true-zen.nvim", - -- Twilight allows to dim text outside of the cursor line. - dependencies = { - "folke/twilight.nvim", - opts = { - -- Set the context to null in order to avoid highlighting to much - -- paragraphs in markdown. - context = 0, - }, - }, - config = function () - require('true-zen').setup({ - modes = { - ataraxis = { - minimum_writing_area = { - width = 100 - } - } - }, - integrations = { - twilight = true, - lualine = true - } - }) - end -} diff --git a/lua/plugins/zen-mode.lua b/lua/plugins/zen-mode.lua new file mode 100644 index 0000000..23682af --- /dev/null +++ b/lua/plugins/zen-mode.lua @@ -0,0 +1,29 @@ +-- Install and configure zen-mode.nvim +-- https://github.com/folke/zen-mode.nvim + +-- Set a keymap to toggle zen mode +vim.keymap.set( + "n", + "z", + "ZenMode", + { desc = "[zen-mode] Toggle zen mode" } +) + +return { + "folke/zen-mode.nvim", + opts = { + -- your configuration comes here + -- or leave it empty to use the default settings + -- refer to the configuration section below + window = { + backdrop = 1, + height = .8, + width = 90, + }, + plugins = { + gitsigns = { + enabled = false, + } + } + } +}