diff --git a/.github/README.md b/.github/README.md index 531d062b..1c3e22c3 100644 --- a/.github/README.md +++ b/.github/README.md @@ -124,16 +124,10 @@ The _recommended_ way of installing **nvf** is using either the NixOS or the Home-Manager module, though it is completely possible and no less supported to install **nvf** as a standalone package, or a flake output. -See the rendered [nvf manual] for detailed and up-to-date installation guides, +See the [**nvf** manual] for detailed and up-to-date installation guides, configurations, available options, release notes and more. Tips for installing userspace plugins is also contained in the documentation. -> [!TIP] -> While using NixOS or Home-Manager modules, -> `programs.nvf.enableManpages = true;` will allow you to view option -> documentation from the comfort of your terminal via `man 5 nvf`. The more you -> know. - Please create an issue on the [issue tracker] if you find the documentation lacking or confusing. Any improvements to the documentation through pull requests are also welcome, and appreciated. diff --git a/docs/release-notes/rl-0.7.md b/docs/release-notes/rl-0.7.md index e030735f..a770952a 100644 --- a/docs/release-notes/rl-0.7.md +++ b/docs/release-notes/rl-0.7.md @@ -103,16 +103,13 @@ everyone. [ocaml-lsp]: https://github.com/ocaml/ocaml-lsp [new-file-template.nvim]: https://github.com/otavioschwanck/new-file-template.nvim -[neo-tree.nvim]: https://github.com/nvim-neo-tree/neo-tree.nvim - Add [ocaml-lsp] support - Fix "Emac" typo - Add [new-file-template.nvim] to automatically fill new file contents using - templates - -- Make [neo-tree.nvim] display file icons properly by enabling `visuals.nvimWebDevicons` + templates. [diniamo](https://github.com/diniamo): @@ -221,10 +218,6 @@ everyone. - Add [](#opt-vim.dashboard.dashboard-nvim.setupOpts) to allow user configuration for [dashboard.nvim](https://github.com/nvimdev/dashboard-nvim) -- Update `lualine.nvim` input and add missing themes: - - Adds `ayu`, `gruvbox_dark`, `iceberg`, `moonfly`, `onedark`, - `powerline_dark` and `solarized_light` themes. - [ppenguin](https://github.com/ppenguin): - Telescope: @@ -236,8 +229,3 @@ everyone. - Add LSP and Treesitter support for R under `vim.languages.R`. - Add Otter support under `vim.lsp.otter` and an assert to prevent conflict with ccc - -[Bloxx12](https://github.com/Bloxx12) - -- Add support for [base16 theming](https://github.com/RRethy/base16-nvim) under - `vim.theme` diff --git a/flake.lock b/flake.lock index bc0859d7..ecc02f27 100644 --- a/flake.lock +++ b/flake.lock @@ -172,22 +172,6 @@ "type": "github" } }, - "plugin-base16": { - "flake": false, - "locked": { - "lastModified": 1716483968, - "narHash": "sha256-GRF/6AobXHamw8TZ3FjL7SI6ulcpwpcohsIuZeCSh2A=", - "owner": "rrethy", - "repo": "base16-nvim", - "rev": "6ac181b5733518040a33017dde654059cd771b7c", - "type": "github" - }, - "original": { - "owner": "rrethy", - "repo": "base16-nvim", - "type": "github" - } - }, "plugin-bufdelete-nvim": { "flake": false, "locked": { @@ -815,11 +799,11 @@ "plugin-lualine": { "flake": false, "locked": { - "lastModified": 1723473562, - "narHash": "sha256-gCm7m96PkZyrgjmt7Efc+NMZKStAq1zr7JRCYOgGDuE=", + "lastModified": 1712310396, + "narHash": "sha256-WcH2dWdRDgMkwBQhcgT+Z/ArMdm+VbRhmQftx4t2kNI=", "owner": "hoob3rt", "repo": "lualine.nvim", - "rev": "b431d228b7bbcdaea818bdc3e25b8cdbe861f056", + "rev": "0a5a66803c7407767b799067986b4dc3036e1983", "type": "github" }, "original": { @@ -1818,7 +1802,6 @@ "nixpkgs": "nixpkgs", "nmd": "nmd", "plugin-alpha-nvim": "plugin-alpha-nvim", - "plugin-base16": "plugin-base16", "plugin-bufdelete-nvim": "plugin-bufdelete-nvim", "plugin-catppuccin": "plugin-catppuccin", "plugin-ccc": "plugin-ccc", diff --git a/flake.nix b/flake.nix index c4a1a2a8..987e3e59 100644 --- a/flake.nix +++ b/flake.nix @@ -349,11 +349,6 @@ }; # Themes - plugin-base16 = { - url = "github:rrethy/base16-nvim"; - flake = false; - }; - plugin-tokyonight = { url = "github:folke/tokyonight.nvim"; flake = false; diff --git a/lib/types/types.nix b/lib/types/custom.nix similarity index 90% rename from lib/types/types.nix rename to lib/types/custom.nix index 250d7636..a94735c5 100644 --- a/lib/types/types.nix +++ b/lib/types/custom.nix @@ -1,9 +1,8 @@ {lib}: let inherit (lib) isStringLike showOption showFiles getFiles mergeOneOption mergeEqualOption mkOptionType; - inherit (lib.strings) isString; inherit (lib.types) anything attrsOf; inherit (lib.nvim.types) anythingConcatLists; - inherit (builtins) typeOf isAttrs any head concatLists stringLength match; + inherit (builtins) typeOf isAttrs any head concatLists stringLength; in { # HACK: Does this break anything in our case? # A modified version of the nixpkgs anything type that concatenates lists @@ -59,11 +58,4 @@ in { check = value: stringLength value < 2; merge = mergeEqualOption; }; - - hexColor = mkOptionType { - name = "hex-color"; - descriptionClass = "noun"; - description = "RGB color in hex format"; - check = v: isString v && (match "#?[0-9a-fA-F]{6}" v) != null; - }; } diff --git a/lib/types/default.nix b/lib/types/default.nix index 70ca6bef..6751229c 100644 --- a/lib/types/default.nix +++ b/lib/types/default.nix @@ -6,10 +6,10 @@ typesDag = import ./dag.nix {inherit lib;}; typesPlugin = import ./plugins.nix {inherit inputs lib;}; typesLanguage = import ./languages.nix {inherit lib;}; - typesTypes = import ./types.nix {inherit lib;}; + typesCustom = import ./custom.nix {inherit lib;}; in { inherit (typesDag) dagOf; inherit (typesPlugin) pluginsOpt extraPluginType mkPluginSetupOption luaInline pluginType borderType; inherit (typesLanguage) diagnostics mkGrammarOption; - inherit (typesTypes) anythingConcatLists char hexColor; + inherit (typesCustom) anythingConcatLists char; } diff --git a/modules/plugins/filetree/neo-tree/config.nix b/modules/plugins/filetree/neo-tree/config.nix index be67df1e..df8e84be 100644 --- a/modules/plugins/filetree/neo-tree/config.nix +++ b/modules/plugins/filetree/neo-tree/config.nix @@ -20,8 +20,6 @@ in { "neo-tree-nvim" ]; - visuals.nvimWebDevicons.enable = true; - pluginRC.neo-tree = entryAnywhere '' require("neo-tree").setup(${toLuaObject cfg.setupOpts}) ''; diff --git a/modules/plugins/statusline/lualine/lualine.nix b/modules/plugins/statusline/lualine/lualine.nix index 1f694eaf..51357941 100644 --- a/modules/plugins/statusline/lualine/lualine.nix +++ b/modules/plugins/statusline/lualine/lualine.nix @@ -17,36 +17,29 @@ "ayu_dark" "ayu_light" "ayu_mirage" - "ayu" "codedark" "dracula" "everforest" "gruvbox" - "gruvbox_dark" "gruvbox_light" "gruvbox_material" "horizon" "iceberg_dark" "iceberg_light" - "iceberg" "jellybeans" "material" "modus_vivendi" "molokai" - "moonfly" "nightfly" "nord" "oceanicnext" - "onedark" "onelight" "palenight" "papercolor_dark" "papercolor_light" - "powerline_dark" "powerline" "seoul256" "solarized_dark" - "solarized_light" "tomorrow" "wombat" ]; @@ -231,7 +224,7 @@ in { local buf_ft = vim.api.nvim_get_option_value('filetype', {}) -- List of buffer types to exclude - local excluded_buf_ft = {"toggleterm", "NvimTree", "neo-tree", "TelescopePrompt"} + local excluded_buf_ft = {"toggleterm", "NvimTree", "TelescopePrompt"} -- Check if the current buffer type is in the excluded list for _, excluded_type in ipairs(excluded_buf_ft) do diff --git a/modules/plugins/theme/supported-themes.nix b/modules/plugins/theme/supported-themes.nix index ca539b1d..63335e41 100644 --- a/modules/plugins/theme/supported-themes.nix +++ b/modules/plugins/theme/supported-themes.nix @@ -4,14 +4,7 @@ }: let inherit (lib.strings) optionalString; inherit (lib.trivial) boolToString warnIf; - inherit (lib.nvim.lua) toLuaObject; in { - base16 = { - setup = {base16-colors, ...}: '' - -- Base16 theme - require('base16-colorscheme').setup(${toLuaObject base16-colors}) - ''; - }; onedark = { setup = {style ? "dark", ...}: '' -- OneDark theme @@ -27,7 +20,6 @@ in { setup = { style ? "night", transparent, - ... }: '' require('tokyonight').setup { transparent = ${boolToString transparent}; @@ -50,7 +42,6 @@ in { setup = { style ? "mocha", transparent ? false, - ... }: '' -- Catppuccin theme require('catppuccin').setup { @@ -78,7 +69,7 @@ in { notify = true, -- nvim-notify which_key = true, navic = { - enabled = true, + enabled = false, custom_bg = "NONE", -- "lualine" will set background to mantle }, }, diff --git a/modules/plugins/theme/theme.nix b/modules/plugins/theme/theme.nix index 95d15d40..85f8430f 100644 --- a/modules/plugins/theme/theme.nix +++ b/modules/plugins/theme/theme.nix @@ -4,51 +4,32 @@ ... }: let inherit (lib.options) mkOption; - inherit (lib.attrsets) attrNames listToAttrs; - inherit (lib.strings) hasPrefix; + inherit (lib.attrsets) attrNames; inherit (lib.types) bool lines enum; inherit (lib.modules) mkIf; inherit (lib.nvim.dag) entryBefore; - inherit (lib.nvim.types) hexColor; cfg = config.vim.theme; supportedThemes = import ./supported-themes.nix { inherit lib config; }; - - numbers = ["0" "1" "2" "3" "4" "5" "6" "7" "8" "9" "A" "B" "C" "D" "E" "F"]; - base16Options = listToAttrs (map (n: { - name = "base0${n}"; - value = mkOption { - description = "The base0${n} color to use"; - type = hexColor; - apply = v: - if hasPrefix "#" v - then v - else "#${v}"; - }; - }) - numbers); in { options.vim.theme = { enable = mkOption { type = bool; description = "Enable theming"; }; + name = mkOption { type = enum (attrNames supportedThemes); - description = '' - Supported themes can be found in {file}`supportedThemes.nix`. - Setting the theme to "base16" enables base16 theming and - requires all of the colors in {option}`vim.theme.base16-colors` to be set. - ''; + description = "Supported themes can be found in `supportedThemes.nix`"; }; - base16-colors = base16Options; style = mkOption { type = enum supportedThemes.${cfg.name}.styles; description = "Specific style for theme if it supports it"; }; + transparent = mkOption { type = bool; default = false; @@ -66,7 +47,7 @@ in { startPlugins = [cfg.name]; luaConfigRC.theme = entryBefore ["pluginConfigs"] '' ${cfg.extraConfig} - ${supportedThemes.${cfg.name}.setup {inherit (cfg) style transparent base16-colors;}} + ${supportedThemes.${cfg.name}.setup {inherit (cfg) style transparent;}} ''; }; };