Created
May 2, 2023 17:24
-
-
Save quanta-kt/336e06ab1ad9322df6fed20092c6545e to your computer and use it in GitHub Desktop.
neovim configuration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vim.opt.number = true | |
vim.opt.autoindent = true | |
vim.opt.tabstop = 4 | |
vim.opt.shiftwidth = 4 | |
vim.opt.spell = true | |
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" | |
if not vim.loop.fs_stat(lazypath) then | |
vim.fn.system({ | |
"git", | |
"clone", | |
"--filter=blob:none", | |
"https://github.com/folke/lazy.nvim.git", | |
"--branch=stable", -- latest stable release | |
lazypath, | |
}) | |
end | |
vim.opt.rtp:prepend(lazypath) | |
require("lazy").setup({ | |
"vim-airline/vim-airline", | |
"preservim/nerdtree", | |
{ "neoclide/coc.nvim", branch = "release" }, | |
"andweeb/presence.nvim", | |
}) | |
require("presence").setup({ | |
-- General options | |
auto_update = true, | |
neovim_image_text = "The One True Text Editor", | |
main_image = "neovim", | |
client_id = "793271441293967371", | |
log_level = nil, | |
debounce_timeout = 10, | |
enable_line_number = false, | |
blacklist = {}, | |
buttons = true, | |
file_assets = {}, | |
show_time = true, | |
-- Rich Presence text options | |
editing_text = "Editing %s", | |
file_explorer_text = "Browsing %s", | |
git_commit_text = "Committing changes", | |
plugin_manager_text = "Managing plugins", | |
reading_text = "Reading %s", | |
workspace_text = "Working on %s", | |
line_number_text = "Line %s out of %s", | |
}) | |
function map(mode, lhs, rhs, opts) | |
local options = { noremap = true } | |
if opts then | |
options = vim.tbl_extend("force", options, opts) | |
end | |
vim.api.nvim_set_keymap(mode, lhs, rhs, options) | |
end | |
map("n", "<C-f>", ":NERDTreeToggle<CR>") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment