From d3790850800162d6742f5724a1dec0c04188ff9e Mon Sep 17 00:00:00 2001 From: Oscar Wallberg Date: Thu, 8 Aug 2024 23:05:59 +0200 Subject: [PATCH] feat(icons): disable icons --- README.md | 33 --------------------------------- lazy-lock.json | 39 +++++++++++++++++++-------------------- lua/lsp.lua | 2 +- lua/plugins/diffview.lua | 9 ++++++--- lua/plugins/lualine.lua | 5 +---- 5 files changed, 27 insertions(+), 61 deletions(-) diff --git a/README.md b/README.md index 1641987..e766efd 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,6 @@ The following are optional but provides additional features: - php - composer - golang -- A nerd font The sections below describes this in more detail. @@ -52,38 +51,6 @@ If you don't need some specific language server, you can disable them in To disable automatic installation of a selected language server, remove or comment out the `mason` part of the configuration at `lua/lsp/config/.lua`. -### Nerd Font -It's recommended to use a [Nerd Font](https://www.nerdfonts.com/), -v3.0.0+, otherwise some icons might not load properly. - -With some terminals it's possible to use a regular font and use the -"symbols only" nerd font as fallback for icons. In those cases it should be -enough to simply install the symbols-only nerd font and it should get picked up -automatically. - -#### [Kitty](https://sw.kovidgoyal.net/kitty/) -[Kitty should pick up the fallback font automatically, and it also supports -mapping specific symbols to a font](https://sw.kovidgoyal.net/kitty/faq/#kitty-is-not-able-to-use-my-favorite-font). - -To map it explicitly you will probably need to change the `symbol_map` for v3 to the following: -```conf -U+23FB-U+23FE,U+2630,U+2665,U+26A1,U+276C-U+2771,U+2B58,U+E000-U+E00A,U+E0A0-U+E0A3,U+E0B0-U+E0C8,U+E0CA,U+E0CC-U+E0D2,U+E0D4,U+E200-U+E2A9,U+E300-U+E3E3,U+E5FA-U+E6AD,U+E700-U+E7C5,U+EA60-U+EA88,U+EA8A-U+EA8C,U+EA8F-U+EAC7,U+EAC9,U+EACC-U+EB09,U+EB0B-U+EB4E,U+EB50-U+EBEB,U+F000-U+F00E,U+F010-U+F01E,U+F021-U+F03E,U+F040-U+F04E,U+F050-U+F05E,U+F060-U+F06E,U+F070-U+F07E,U+F080-U+F08E,U+F090-U+F09E,U+F0A0-U+F0AE,U+F0B0-U+F0B2,U+F0C0-U+F0CE,U+F0D0-U+F0DE,U+F0E0-U+F0EE,U+F0F0-U+F0FE,U+F100-U+F10E,U+F110-U+F11E,U+F120-U+F12E,U+F130-U+F13E,U+F140-U+F14E,U+F150-U+F15E,U+F160-U+F16E,U+F170-U+F17E,U+F180-U+F18E,U+F190-U+F19E,U+F1A0-U+F1AE,U+F1B0-U+F1BE,U+F1C0-U+F1CE,U+F1D0-U+F1DE,U+F1E0-U+F1EE,U+F1F0-U+F1FE,U+F200-U+F20E,U+F210-U+F21E,U+F221-U+F23E,U+F240-U+F24E,U+F250-U+F25E,U+F260-U+F26E,U+F270-U+F27E,U+F280-U+F28E,U+F290-U+F29E,U+F2A0-U+F2AE,U+F2B0-U+F2BE,U+F2C0-U+F2CE,U+F2D0-U+F2DE,U+F2E0,U+F300-U+F32F,U+F400-U+F533,U+F0001-U+F1AF0 Symbols Nerd Font Mono -``` - -Alternatively generate it yourself with: -```sh -fc-query /path/to/your/font.ttf --format='%{charset}\n' | sed -r 's/([0-9a-f]+)/U+\U\1/g' | sed 's/ /,/g' -``` - -#### [Alacritty](https://alacritty.org/) -Alacritty should automatically pick it up from the symbols-only nerd font. But -as of writing it is not possible to configure explicitly. - -#### [Wezterm](https://wezfurlong.org/wezterm/index.html) -Wezterm has [built-in fallback for nerd fonts symbols](https://wezfurlong.org/wezterm/config/lua/wezterm/nerdfonts.html), -so there's no need to install it separately. It is also possible to configure -fallbacks manually. - ### Clipboard see `:checkhealth` and `:h clipboard`. diff --git a/lazy-lock.json b/lazy-lock.json index bb07d76..8631839 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -6,32 +6,31 @@ "cmp-nvim-lsp": { "branch": "main", "commit": "39e2eda76828d88b773cc27a3f61d2ad782c922d" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "diffview.nvim": { "branch": "main", "commit": "3afa6a053f680e9f1329c4a151db988a482306cd" }, + "context.vim": { "branch": "master", "commit": "82eb26de265292808917b82f3eda2725b53d785c" }, + "diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" }, "fidget.nvim": { "branch": "main", "commit": "0ba1e16d07627532b6cae915cc992ecac249fb97" }, "fm-nvim": { "branch": "master", "commit": "8e6a77049330e7c797eb9e63affd75eb796fe75e" }, - "friendly-snippets": { "branch": "main", "commit": "700c4a25caacbb4648c9a27972c2fe203948e0c2" }, - "gitsigns.nvim": { "branch": "main", "commit": "4a143f13e122ab91abdc88f89eefbe70a4858a56" }, + "friendly-snippets": { "branch": "main", "commit": "00ebcaa159e817150bd83bfe2d51fa3b3377d5c4" }, + "gitsigns.nvim": { "branch": "main", "commit": "562dc47189ad3c8696dbf460d38603a74d544849" }, "grapple.nvim": { "branch": "main", "commit": "7aedc261b05a6c030397c4bc26416efbe746ebf1" }, - "lazy.nvim": { "branch": "main", "commit": "eb4957442e3182f051b0ae11da32e06d22c190e3" }, + "lazy.nvim": { "branch": "main", "commit": "077102c5bfc578693f12377846d427f49bc50076" }, "lsp-inlayhints.nvim": { "branch": "anticonceal", "commit": "0fb3b5ef16f2d7e85963cb0b1beacf573ade35de" }, - "lspkind.nvim": { "branch": "master", "commit": "1735dd5a5054c1fb7feaf8e8658dbab925f4f0cf" }, - "lualine.nvim": { "branch": "master", "commit": "0a5a66803c7407767b799067986b4dc3036e1983" }, - "mason.nvim": { "branch": "main", "commit": "0950b15060067f752fde13a779a994f59516ce3d" }, - "moonfly": { "branch": "master", "commit": "ed4b1b1220a6f040bd17043ae7c9458af0a3b16b" }, + "lspkind.nvim": { "branch": "master", "commit": "cff4ae321a91ee3473a92ea1a8c637e3a9510aec" }, + "lualine.nvim": { "branch": "master", "commit": "544dd1583f9bb27b393f598475c89809c4d5e86b" }, + "mason.nvim": { "branch": "main", "commit": "e2f7f9044ec30067bc11800a9e266664b88cda22" }, + "moonfly": { "branch": "master", "commit": "4f7d18cb471ede7407dd966c7563868cae7f4f99" }, "move.nvim": { "branch": "main", "commit": "cccbd4ea9049ca5f99f025ffaddb7392359c7d6a" }, - "nvim-cmp": { "branch": "main", "commit": "a110e12d0b58eefcf5b771f533fc2cf3050680ac" }, - "nvim-colorizer.lua": { "branch": "master", "commit": "85855b38011114929f4058efc97af1059ab3e41d" }, - "nvim-lspconfig": { "branch": "master", "commit": "4d38bece98300e3e5cd24a9aa0d0ebfea4951c16" }, + "nvim-cmp": { "branch": "main", "commit": "ae644feb7b67bf1ce4260c231d1d4300b19c6f30" }, + "nvim-colorizer.lua": { "branch": "master", "commit": "194ec600488f7c7229668d0e80bd197f3a2b84ff" }, + "nvim-lspconfig": { "branch": "master", "commit": "652386deae739e38fa1bcf2f06e3e7de9b3436ba" }, "nvim-notify": { "branch": "master", "commit": "d333b6f167900f6d9d42a59005d82919830626bf" }, - "nvim-treesitter": { "branch": "master", "commit": "f29c2d9867004151f9417f2f19b068fb973c29cc" }, - "nvim-treesitter-context": { "branch": "master", "commit": "5efba33af0f39942e426340da7bc15d7dec16474" }, - "nvim-web-devicons": { "branch": "master", "commit": "c0cfc1738361b5da1cd0a962dd6f774cc444f856" }, - "orgmode": { "branch": "master", "commit": "e91b94cf29b24e62558218343b464d2a1ef44c03" }, + "nvim-treesitter": { "branch": "master", "commit": "a8535b2329a082c7f4e0b11b91b1792770425eaa" }, + "orgmode": { "branch": "master", "commit": "de02a0cfbe3484accb73025b6dd71b2cc4ae3eff" }, "plenary.nvim": { "branch": "master", "commit": "a3e3bc82a3f95c5ed0d7201546d5d2c19b20d683" }, - "telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" }, - "telescope.nvim": { "branch": "master", "commit": "f12b15e1b3a33524eb06a1ae7bc852fb1fd92197" }, - "vim-flog": { "branch": "master", "commit": "2f0836128cac9368176a564b237382d1766723f0" }, - "vim-fugitive": { "branch": "master", "commit": "4f59455d2388e113bd510e85b310d15b9228ca0d" }, + "telescope-fzf-native.nvim": { "branch": "main", "commit": "cf48d4dfce44e0b9a2e19a008d6ec6ea6f01a83b" }, + "telescope.nvim": { "branch": "master", "commit": "3b1600d0fd5172ad9fae00987362ca0ef3d8895d" }, + "vim-flog": { "branch": "master", "commit": "dd7a1cf09d034ffa063bedfef4f13891eff06f3a" }, + "vim-fugitive": { "branch": "master", "commit": "0444df68cd1cdabc7453d6bd84099458327e5513" }, "winresizer": { "branch": "master", "commit": "9bd559a03ccec98a458e60c705547119eb5350f3" }, "winshift.nvim": { "branch": "main", "commit": "37468ed6f385dfb50402368669766504c0e15583" } -} \ No newline at end of file +} diff --git a/lua/lsp.lua b/lua/lsp.lua index dfcc95d..1a3baae 100644 --- a/lua/lsp.lua +++ b/lua/lsp.lua @@ -130,7 +130,7 @@ local function setup_diagnostics() update_in_insert = false, severity_sort = false, }) - local signs = { Error = "󰅚 ", Warn = "󰀪 ", Hint = "󰌶 ", Info = " " } + local signs = { Error = "E", Warn = "W", Hint = "H", Info = "I" } for type, icon in pairs(signs) do local hl = "DiagnosticSign" .. type vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = hl }) diff --git a/lua/plugins/diffview.lua b/lua/plugins/diffview.lua index ac3704f..c75838c 100644 --- a/lua/plugins/diffview.lua +++ b/lua/plugins/diffview.lua @@ -3,9 +3,6 @@ ---@type LazyPluginSpec return { "sindrets/diffview.nvim", - dependencies = { - "nvim-tree/nvim-web-devicons", - }, keys = { { "gg", vim.cmd.DiffviewOpen, mode = "n" }, }, @@ -13,6 +10,12 @@ return { local actions = require("diffview.actions") require("diffview").setup({ enhanced_diff_hl = true, + use_icons = false, + signs = { + fold_closed = "+ ", + fold_open = "- ", + done = "", + }, view = { default = { layout = "diff2_horizontal", diff --git a/lua/plugins/lualine.lua b/lua/plugins/lualine.lua index 3e020aa..b567acb 100644 --- a/lua/plugins/lualine.lua +++ b/lua/plugins/lualine.lua @@ -5,16 +5,13 @@ return { "nvim-lualine/lualine.nvim", lazy = true, event = "VimEnter", - dependencies = { - "nvim-tree/nvim-web-devicons", - }, config = function() local custom_moonfly = require("lualine.themes.moonfly") custom_moonfly.normal.c.bg = require("moonfly").palette.bg require("lualine").setup({ options = { - icons_enabled = true, + icons_enabled = false, theme = custom_moonfly, component_separators = { left = "", right = "" }, section_separators = { left = "", right = "" },