diff --git a/.config/nvim/README.md b/.config/nvim/README.md deleted file mode 100644 index 190e400..0000000 --- a/.config/nvim/README.md +++ /dev/null @@ -1,32 +0,0 @@ -# Neovim Configuration - -Running neovim with packer for plugins and lsp stuff. - -`init.lua` is the entry point for neovim. -`plugin/*.lua` run on startup. - -## Plugins & LSP - -```sh -:PackerInstall -:PackerUpdate -:Mason -> U # Update all LSP servers -``` - -Mason should auto-install LSP servers. However, the following is what should be installed: - -- `prettier` -- `lua-language-server` -- `luaformatter` -- `eslint_d` -- `typescript-language-server` -- `stylelint-lsp` - -`prettierd` and `eslintd` will need to be installed manually via pnpm as a global package. - -## Custom key binds - -- `f` to toggle NerdTREE -- `?` to view code action items -- `>` to go to next diagnostic -- `<` to go to previous diagnostic diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua index 442602a..f368138 100644 --- a/.config/nvim/init.lua +++ b/.config/nvim/init.lua @@ -1,4 +1,100 @@ -require('pfych.base') -require('pfych.plugins') -require('pfych.colours') -require('pfych.keybinds') +-- Bootstrap lazy.nvim +local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" +if not (vim.uv or vim.loop).fs_stat(lazypath) then + local lazyrepo = "https://github.com/folke/lazy.nvim.git" + local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) + if vim.v.shell_error ~= 0 then + vim.api.nvim_echo({ + { "Failed to clone lazy.nvim:\n", "ErrorMsg" }, + { out, "WarningMsg" }, + { "\nPress any key to exit..." }, + }, true, {}) + vim.fn.getchar() + os.exit(1) + end +end +vim.opt.rtp:prepend(lazypath) + +-- Basic Vim config +vim.cmd("autocmd!") +vim.g.mapleader = " " +vim.g.maplocalleader = "\\" +vim.scriptencoding = 'utf-8' +vim.opt.encoding = 'utf-8' +vim.opt.fileencoding = 'utf-8' +vim.wo.relativenumber = true +vim.wo.number = true +vim.opt.title = true +vim.opt.autoindent = true +vim.opt.smartindent = true +vim.opt.smarttab = true +vim.opt.expandtab = true +vim.opt.breakindent = true +vim.opt.shiftwidth = 2 +vim.opt.tabstop = 2 +vim.opt.mouse = "a" +vim.opt.undofile = true +vim.opt.undodir = vim.fn.expand('~/.vim/undodir') +vim.opt.wrap = true +vim.opt.linebreak = true +vim.opt.breakindent = true +vim.opt.breakindentopt = "shift:2,min:40,sbr" + +-- Plugin setup +require("lazy").setup({ + spec = { + { + "catppuccin/nvim", + name = "catppuccin", + lazy = false, + priority = 1000 + }, + { "neovim/nvim-lspconfig" }, + { "hrsh7th/nvim-cmp" }, + { "hrsh7th/cmp-nvim-lsp" }, + { "hrsh7th/cmp-buffer" } + }, + install = {}, + checker = { enabled = true } +}) + +-- Colour setup +require("catppuccin").setup({ + flavour = "mocha", -- latte, frappe, macchiato, mocha + background = { + light = "latte", + dark = "mocha", + }, + transparent_background = false, + no_italic = false, + no_bold = false, + styles = { + comments = { "italic" }, + }, + color_overrides = {}, + integrations = { + cmp = true, + }, +}) + +vim.cmd('colorscheme catppuccin') +vim.api.nvim_set_hl(0, "Normal", { guibg = NONE, ctermbg = NONE }) + +-- LSP Setup +local nvim_lsp = require("lspconfig") +local capabilities = require('cmp_nvim_lsp').default_capabilities() + +nvim_lsp.lua_ls.setup { + capabilities = capabilities, + settings = { + Lua = { + diagnostics = { + globals = { 'vim' }, + }, + workspace = { + library = vim.api.nvim_get_runtime_file("", true), + checkThirdParty = false + }, + }, + }, +} diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json new file mode 100644 index 0000000..ba15f4b --- /dev/null +++ b/.config/nvim/lazy-lock.json @@ -0,0 +1,8 @@ +{ + "catppuccin": { "branch": "main", "commit": "4bb938bbba41d306db18bf0eb0633a5f28fd7ba0" }, + "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, + "cmp-nvim-lsp": { "branch": "main", "commit": "99290b3ec1322070bcfb9e846450a46f6efa50f0" }, + "lazy.nvim": { "branch": "main", "commit": "e5e9bf48211a13d9ee6c1077c88327c49c1ab4a0" }, + "nvim-cmp": { "branch": "main", "commit": "12509903a5723a876abd65953109f926f4634c30" }, + "nvim-lspconfig": { "branch": "master", "commit": "7c8cb61b21727a473663054edec4b83633d9e442" } +} diff --git a/.config/nvim/lua/pfych/base.lua b/.config/nvim/lua/pfych/base.lua deleted file mode 100644 index b98df67..0000000 --- a/.config/nvim/lua/pfych/base.lua +++ /dev/null @@ -1,30 +0,0 @@ -vim.cmd("autocmd!") - -vim.scriptencoding = 'utf-8' -vim.opt.encoding = 'utf-8' -vim.opt.fileencoding = 'utf-8' - -vim.wo.relativenumber = true -vim.wo.number = true - -vim.opt.title = true -vim.opt.autoindent = true -vim.opt.smartindent = true -vim.opt.smarttab = true -vim.opt.expandtab = true -vim.opt.breakindent = true -vim.opt.shiftwidth = 2 -vim.opt.tabstop = 2 -vim.opt.mouse = "a" -vim.opt.undofile = true -vim.opt.undodir = vim.fn.expand('~/.vim/undodir') - --- UXN Assembly on save -vim.cmd("command Uxnasm !uxnasm % %<.rom") -vim.cmd("autocmd BufWritePost *.tal :Uxnasm") - --- Line wrap config -vim.opt.wrap = true -vim.opt.linebreak = true -vim.opt.breakindent = true -vim.opt.breakindentopt = "shift:2,min:40,sbr" diff --git a/.config/nvim/lua/pfych/colours.lua b/.config/nvim/lua/pfych/colours.lua deleted file mode 100644 index d9d3369..0000000 --- a/.config/nvim/lua/pfych/colours.lua +++ /dev/null @@ -1,33 +0,0 @@ -require("catppuccin").setup({ - flavour = "mocha", -- latte, frappe, macchiato, mocha - background = { -- :h background - light = "latte", - dark = "mocha", - }, - transparent_background = false, - no_italic = false, -- Force no italic - no_bold = false, -- Force no bold - styles = { - comments = { "italic" }, - conditionals = {}, - loops = {}, - functions = {}, - keywords = {}, - strings = {}, - variables = {}, - numbers = {}, - booleans = {}, - properties = {}, - types = {}, - operators = {}, - }, - color_overrides = { - }, - integrations = { - cmp = true, - }, -}) - --- setup must be called before loading -vim.cmd('colorscheme catppuccin') -vim.api.nvim_set_hl(0, "Normal", { guibg = NONE, ctermbg = NONE }) diff --git a/.config/nvim/lua/pfych/keybinds.lua b/.config/nvim/lua/pfych/keybinds.lua deleted file mode 100644 index 1d7d3fa..0000000 --- a/.config/nvim/lua/pfych/keybinds.lua +++ /dev/null @@ -1,7 +0,0 @@ --- CodeActionsMenu with ? -vim.api.nvim_set_keymap("n", "?", ":CodeActionMenu", { silent = true, noremap = true }) -vim.api.nvim_set_keymap("n", ">", ":lua vim.diagnostic.goto_next()", { silent = true, noremap = true }) -vim.api.nvim_set_keymap("n", "<", ":lua vim.diagnostic.goto_prev()", { silent = true, noremap = true }) - -vim.opt.splitright = true -vim.api.nvim_set_keymap("n", "f", ":NERDTreeToggle", { noremap = true }) diff --git a/.config/nvim/lua/pfych/plugins.lua b/.config/nvim/lua/pfych/plugins.lua deleted file mode 100644 index 474ce2e..0000000 --- a/.config/nvim/lua/pfych/plugins.lua +++ /dev/null @@ -1,31 +0,0 @@ -local status, packer = pcall(require, "packer") -if (not status) then - print("Packer is not installed") - return -end - -vim.cmd [[packadd packer.nvim]] - -packer.startup(function(use) - use 'wbthomason/packer.nvim' - - use 'hrsh7th/cmp-buffer' -- nvim-cmp source for buffer words - use 'hrsh7th/cmp-nvim-lsp' -- nvim-cmp source for neovim's built-in LSP - use 'hrsh7th/nvim-cmp' -- Completion - use 'L3MON4D3/LuaSnip' - use 'neovim/nvim-lspconfig' -- LSP - use 'jose-elias-alvarez/null-ls.nvim' - use 'williamboman/mason.nvim' -- LSP Installer - use 'williamboman/mason-lspconfig.nvim' - use 'nvim-tree/nvim-web-devicons' - use { 'catppuccin/nvim', as = "catppuccin" } - use { - 'nvim-telescope/telescope.nvim', tag = '0.1.8', -- For file searching :Telescope find_files - requires = { { 'nvim-lua/plenary.nvim' } } - } - use { 'prettier/vim-prettier', build = 'pnpm install' } - use { 'weilbith/nvim-code-action-menu', cmd = 'CodeActionMenu' } - use 'bellinitte/uxntal.vim' - use 'preservim/nerdtree' -- For file-browser :NERDTree - use 'elkowar/yuck.vim' -end) diff --git a/.config/nvim/plugin/cmp.lua b/.config/nvim/plugin/cmp.lua deleted file mode 100644 index b53e8be..0000000 --- a/.config/nvim/plugin/cmp.lua +++ /dev/null @@ -1,33 +0,0 @@ -local cmp = require'cmp' - -local cmpStatus, cmp = pcall(require, "cmp") -if (not cmpStatus) then - print("cmp is not installed") - return -end - -cmp.setup({ - snippet = { - expand = function(args) - require('luasnip').lsp_expand(args.body) - end, - }, - mapping = cmp.mapping.preset.insert({ - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - local entry = cmp.get_selected_entry() - if not entry then - cmp.select_next_item({ behavior = cmp.SelectBehavior.Select }) - else - cmp.confirm() - end - else - fallback() - end - end, {"i","s","c",}), - }), - sources = cmp.config.sources({ - { name = 'nvim_lsp' }, - { name = 'buffer' }, - }) -}) diff --git a/.config/nvim/plugin/lspconfig.lua b/.config/nvim/plugin/lspconfig.lua deleted file mode 100644 index 104b445..0000000 --- a/.config/nvim/plugin/lspconfig.lua +++ /dev/null @@ -1,117 +0,0 @@ -local status, nvim_lsp = pcall(require, "lspconfig") -if (not status) then - print("LSPConfig is not installed") - return -end - -local protocol = require('vim.lsp.protocol') - -local augroup_format = vim.api.nvim_create_augroup("Format", { clear = true }) -local enable_format_on_save = function(_, bufnr) - vim.api.nvim_clear_autocmds({ group = augroup_format, buffer = bufnr }) - vim.api.nvim_create_autocmd("BufWritePre", { - group = augroup_format, - buffer = bufnr, - callback = function() - vim.lsp.buf.format({ bufnr = bufnr }) - end, - }) -end - -local on_attach = function(client, bufnr) - local function buf_set_keymap(...) vim.api.nvim_buf_set_keymap(bufnr, ...) end - - local opts = { noremap = true, silent = true } - - buf_set_keymap('n', 'gD', 'lua vim.lsp.buf.declaration()', opts) - buf_set_keymap('n', 'gi', 'lua vim.lsp.buf.implementation()', opts) -end - -protocol.CompletionItemKind = { - '', -- Text - '', -- Method - '', -- Function - '', -- Constructor - '', -- Field - '', -- Variable - '', -- Class - 'ﰮ', -- Interface - '', -- Module - '', -- Property - '', -- Unit - '', -- Value - '', -- Enum - '', -- Keyword - '﬌', -- Snippet - '', -- Color - '', -- File - '', -- Reference - '', -- Folder - '', -- EnumMember - '', -- Constant - '', -- Struct - '', -- Event - 'ﬦ', -- Operator - '', -- TypeParameter -} - --- Set up completion using nvim_cmp with LSP source -local capabilities = require('cmp_nvim_lsp').default_capabilities() - -nvim_lsp.stylelint_lsp.setup { - filetypes = { "css", "scss" } -} - -nvim_lsp.ts_ls.setup { - on_attach = on_attach, - filetypes = { "typescript", "typescriptreact", "typescript.tsx" }, - cmd = { "typescript-language-server", "--stdio" }, - capabilities = capabilities -} - -nvim_lsp.lua_ls.setup { - capabilities = capabilities, - on_attach = function(client, bufnr) - on_attach(client, bufnr) - enable_format_on_save(client, bufnr) - end, - settings = { - Lua = { - diagnostics = { - -- Get the language server to recognize the `vim` global - globals = { 'vim' }, - }, - workspace = { - -- Make the server aware of Neovim runtime files - library = vim.api.nvim_get_runtime_file("", true), - checkThirdParty = false - }, - }, - }, -} - -vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with( - vim.lsp.diagnostic.on_publish_diagnostics, { - underline = true, - update_in_insert = false, - virtual_text = { spacing = 4, prefix = "●" }, - severity_sort = true, - } -) - --- Diagnostic symbols in the sign column (gutter) -local signs = { Error = " ", Warn = " ", Hint = " ", Info = " " } -for type, icon in pairs(signs) do - local hl = "DiagnosticSign" .. type - vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = "" }) -end - -vim.diagnostic.config({ - virtual_text = { - prefix = '●' - }, - update_in_insert = true, - float = { - source = "always", -- Or "if_many" - }, -}) diff --git a/.config/nvim/plugin/mason.lua b/.config/nvim/plugin/mason.lua deleted file mode 100644 index 808b3b9..0000000 --- a/.config/nvim/plugin/mason.lua +++ /dev/null @@ -1,17 +0,0 @@ -local status, mason = pcall(require, "mason") -if (not status) then - print("Mason is not installed") - return -end - -mason.setup({ - ensure_installed = { - "prettier", - "lua-language-server", - "luaformatter", - "eslint_d", - "typescript-language-server", - "stylelint-lsp" - }, - automatic_installation = true -}) diff --git a/.config/nvim/plugin/null-ls.lua b/.config/nvim/plugin/null-ls.lua deleted file mode 100644 index d0274db..0000000 --- a/.config/nvim/plugin/null-ls.lua +++ /dev/null @@ -1,43 +0,0 @@ -local status, null_ls = pcall(require, "null-ls") -if (not status) then return end - -local augroup = vim.api.nvim_create_augroup("LspFormatting", {}) - -local lsp_formatting = function(bufnr) - vim.lsp.buf.format({ - filter = function(client) - return client.name == "null-ls" - end, - bufnr = bufnr, - }) -end - -null_ls.setup { - sources = { - null_ls.builtins.formatting.prettierd, - null_ls.builtins.diagnostics.eslint_d.with({ - diagnostics_format = '[eslint] #{m}\n(#{c})' - }), - null_ls.builtins.diagnostics.fish - }, - on_attach = function(client, bufnr) - if client.supports_method("textDocument/formatting") then - vim.api.nvim_clear_autocmds({ group = augroup, buffer = bufnr }) - vim.api.nvim_create_autocmd("BufWritePre", { - group = augroup, - buffer = bufnr, - callback = function() - lsp_formatting(bufnr) - end, - }) - end - end -} - -vim.api.nvim_create_user_command( - 'DisableLspFormatting', - function() - vim.api.nvim_clear_autocmds({ group = augroup, buffer = 0 }) - end, - { nargs = 0 } -) diff --git a/.config/nvim/plugin/packer_compiled.lua b/.config/nvim/plugin/packer_compiled.lua deleted file mode 100644 index 2818f91..0000000 --- a/.config/nvim/plugin/packer_compiled.lua +++ /dev/null @@ -1,199 +0,0 @@ --- Automatically generated packer.nvim plugin loader code - -if vim.api.nvim_call_function('has', {'nvim-0.5'}) ~= 1 then - vim.api.nvim_command('echohl WarningMsg | echom "Invalid Neovim version for packer.nvim! | echohl None"') - return -end - -vim.api.nvim_command('packadd packer.nvim') - -local no_errors, error_msg = pcall(function() - -_G._packer = _G._packer or {} -_G._packer.inside_compile = true - -local time -local profile_info -local should_profile = false -if should_profile then - local hrtime = vim.loop.hrtime - profile_info = {} - time = function(chunk, start) - if start then - profile_info[chunk] = hrtime() - else - profile_info[chunk] = (hrtime() - profile_info[chunk]) / 1e6 - end - end -else - time = function(chunk, start) end -end - -local function save_profiles(threshold) - local sorted_times = {} - for chunk_name, time_taken in pairs(profile_info) do - sorted_times[#sorted_times + 1] = {chunk_name, time_taken} - end - table.sort(sorted_times, function(a, b) return a[2] > b[2] end) - local results = {} - for i, elem in ipairs(sorted_times) do - if not threshold or threshold and elem[2] > threshold then - results[i] = elem[1] .. ' took ' .. elem[2] .. 'ms' - end - end - if threshold then - table.insert(results, '(Only showing plugins that took longer than ' .. threshold .. ' ms ' .. 'to load)') - end - - _G._packer.profile_output = results -end - -time([[Luarocks path setup]], true) -local package_path_str = "/Users/noah/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/Users/noah/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/Users/noah/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/Users/noah/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua" -local install_cpath_pattern = "/Users/noah/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so" -if not string.find(package.path, package_path_str, 1, true) then - package.path = package.path .. ';' .. package_path_str -end - -if not string.find(package.cpath, install_cpath_pattern, 1, true) then - package.cpath = package.cpath .. ';' .. install_cpath_pattern -end - -time([[Luarocks path setup]], false) -time([[try_loadstring definition]], true) -local function try_loadstring(s, component, name) - local success, result = pcall(loadstring(s), name, _G.packer_plugins[name]) - if not success then - vim.schedule(function() - vim.api.nvim_notify('packer.nvim: Error running ' .. component .. ' for ' .. name .. ': ' .. result, vim.log.levels.ERROR, {}) - end) - end - return result -end - -time([[try_loadstring definition]], false) -time([[Defining packer_plugins]], true) -_G.packer_plugins = { - LuaSnip = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/LuaSnip", - url = "https://github.com/L3MON4D3/LuaSnip" - }, - catppuccin = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/catppuccin", - url = "https://github.com/catppuccin/nvim" - }, - ["cmp-buffer"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/cmp-buffer", - url = "https://github.com/hrsh7th/cmp-buffer" - }, - ["cmp-nvim-lsp"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp", - url = "https://github.com/hrsh7th/cmp-nvim-lsp" - }, - ["mason-lspconfig.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/mason-lspconfig.nvim", - url = "https://github.com/williamboman/mason-lspconfig.nvim" - }, - ["mason.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/mason.nvim", - url = "https://github.com/williamboman/mason.nvim" - }, - ["null-ls.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/null-ls.nvim", - url = "https://github.com/jose-elias-alvarez/null-ls.nvim" - }, - ["nvim-cmp"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/nvim-cmp", - url = "https://github.com/hrsh7th/nvim-cmp" - }, - ["nvim-code-action-menu"] = { - commands = { "CodeActionMenu" }, - loaded = false, - needs_bufread = true, - only_cond = false, - path = "/Users/noah/.local/share/nvim/site/pack/packer/opt/nvim-code-action-menu", - url = "https://github.com/weilbith/nvim-code-action-menu" - }, - ["nvim-lspconfig"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/nvim-lspconfig", - url = "https://github.com/neovim/nvim-lspconfig" - }, - ["nvim-treesitter"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/nvim-treesitter", - url = "https://github.com/nvim-treesitter/nvim-treesitter" - }, - ["nvim-web-devicons"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/nvim-web-devicons", - url = "https://github.com/nvim-tree/nvim-web-devicons" - }, - ["packer.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/packer.nvim", - url = "https://github.com/wbthomason/packer.nvim" - }, - ["plenary.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/plenary.nvim", - url = "https://github.com/nvim-lua/plenary.nvim" - }, - ["telescope-file-browser.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/telescope-file-browser.nvim", - url = "https://github.com/nvim-telescope/telescope-file-browser.nvim" - }, - ["telescope.nvim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/telescope.nvim", - url = "https://github.com/nvim-telescope/telescope.nvim" - }, - ["uxntal.vim"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/uxntal.vim", - url = "https://github.com/bellinitte/uxntal.vim" - }, - ["vim-prettier"] = { - loaded = true, - path = "/Users/noah/.local/share/nvim/site/pack/packer/start/vim-prettier", - url = "https://github.com/prettier/vim-prettier" - } -} - -time([[Defining packer_plugins]], false) - --- Command lazy-loads -time([[Defining lazy-load commands]], true) -pcall(vim.api.nvim_create_user_command, 'CodeActionMenu', function(cmdargs) - require('packer.load')({'nvim-code-action-menu'}, { cmd = 'CodeActionMenu', l1 = cmdargs.line1, l2 = cmdargs.line2, bang = cmdargs.bang, args = cmdargs.args, mods = cmdargs.mods }, _G.packer_plugins) - end, - {nargs = '*', range = true, bang = true, complete = function() - require('packer.load')({'nvim-code-action-menu'}, {}, _G.packer_plugins) - return vim.fn.getcompletion('CodeActionMenu ', 'cmdline') - end}) -time([[Defining lazy-load commands]], false) - - -_G._packer.inside_compile = false -if _G._packer.needs_bufread == true then - vim.cmd("doautocmd BufRead") -end -_G._packer.needs_bufread = false - -if should_profile then save_profiles() end - -end) - -if not no_errors then - error_msg = error_msg:gsub('"', '\\"') - vim.api.nvim_command('echohl ErrorMsg | echom "Error in packer_compiled: '..error_msg..'" | echom "Please check your config for correctness" | echohl None') -end diff --git a/.config/nvim/plugin/telescope.lua b/.config/nvim/plugin/telescope.lua deleted file mode 100644 index 7313b9d..0000000 --- a/.config/nvim/plugin/telescope.lua +++ /dev/null @@ -1,7 +0,0 @@ -local status, telescope = pcall(require, "telescope") -if (not status) then - print("Telescope is not installed") - return -end - -telescope.setup({}) diff --git a/.config/nvim/plugin/treesitter.lua b/.config/nvim/plugin/treesitter.lua deleted file mode 100644 index c83fa68..0000000 --- a/.config/nvim/plugin/treesitter.lua +++ /dev/null @@ -1,31 +0,0 @@ -local status, ts = pcall(require, "nvim-treesitter.configs") -if (not status) then return end - -ts.setup { - highlight = { - enable = true, - disable = {}, - }, - indent = { - enable = true, - disable = {}, - }, - ensure_installed = { - "markdown", - "markdown_inline", - "tsx", - "json", - "yaml", - "css", - "scss", - "html", - "lua", - "vim", - }, - autotag = { - enable = true, - }, -} - -local parser_config = require "nvim-treesitter.parsers".get_parser_configs() -parser_config.tsx.filetype_to_parsername = { "javascript", "typescript.tsx" }