Correct mistakes and add configs and initializations
This commit is contained in:
parent
623ef3a48d
commit
f34eee4399
4
init.lua
4
init.lua
|
@ -1,8 +1,8 @@
|
|||
require('plugins')
|
||||
require('post_plugins')
|
||||
require('platform')
|
||||
require('custom')
|
||||
require('settings')
|
||||
require('plugins')
|
||||
require('post_plugins')
|
||||
require('plugin_options')
|
||||
require('utilities')
|
||||
require('keymaps')
|
||||
|
|
|
@ -1,13 +1,18 @@
|
|||
vim.cmd([[
|
||||
augroup packer_user_config
|
||||
autocmd!
|
||||
autocmd BufWritePost plugins.lua source <afile> | PackerCompile
|
||||
augroup end
|
||||
]])
|
||||
-- vim.cmd([[
|
||||
-- augroup packer_user_config
|
||||
-- autocmd!
|
||||
-- autocmd BufWritePost plugins.lua source <afile> | PackerCompile
|
||||
-- augroup end
|
||||
-- ]])
|
||||
|
||||
return require('packer').startup(function(use)
|
||||
-- Packer can manage itself
|
||||
use 'wbthomason/packer.nvim'
|
||||
use {
|
||||
'wbthomason/packer.nvim',
|
||||
config = function()
|
||||
vim.keymap.set('n', '<leader>ps', ':PackerSync<cr>', { noremap = true })
|
||||
end
|
||||
}
|
||||
|
||||
-- ===
|
||||
-- Core
|
||||
|
@ -38,13 +43,49 @@ return require('packer').startup(function(use)
|
|||
config = function()
|
||||
require('lualine').setup {
|
||||
options = {
|
||||
theme = 'dracula'
|
||||
theme = 'dracula',
|
||||
component_separators = { left = '', right = '' },
|
||||
section_separators = { left = '', right = '' },
|
||||
icons_enabled = true,
|
||||
globalstatus = true
|
||||
}
|
||||
}
|
||||
end
|
||||
}
|
||||
end
|
||||
|
||||
if vim.g.use_tabline == true then
|
||||
use {
|
||||
'kdheepak/tabline.nvim',
|
||||
config = function()
|
||||
require('tabline').setup {
|
||||
-- Defaults configuration options
|
||||
enable = true,
|
||||
options = {
|
||||
-- If lualine is installed tabline will use separators configured in lualine by default.
|
||||
-- These options can be used to override those settings.
|
||||
--section_separators = {'', ''},
|
||||
--component_separators = {'', ''},
|
||||
--max_bufferline_percent = 66, -- set to nil by default, and it uses vim.o.columns * 2/3
|
||||
show_tabs_always = true, -- this shows tabs only when there are more than one tab or if the first tab is named
|
||||
show_devicons = false, -- this shows devicons in buffer section
|
||||
show_bufnr = false, -- this appends [bufnr] to buffer section,
|
||||
show_filename_only = false, -- shows base filename only instead of relative path in filename
|
||||
modified_icon = "+ ", -- change the default modified icon
|
||||
modified_italic = false, -- set to true by default; this determines whether the filename turns italic if modified
|
||||
show_tabs_only = false, -- this shows only tabs instead of tabs + buffers
|
||||
}
|
||||
}
|
||||
|
||||
vim.cmd([[
|
||||
set guioptions-=e " Use showtabline in gui vim
|
||||
set sessionoptions+=tabpages,globals " store tabpages and globals in session
|
||||
]])
|
||||
end
|
||||
-- requires = { { 'nvim-lualine/lualine.nvim', opt=true }, {'kyazdani42/nvim-web-devicons', opt = true} }
|
||||
}
|
||||
end
|
||||
|
||||
if vim.g.use_comfortable_motion == true then
|
||||
use 'yuttie/comfortable-motion.vim'
|
||||
end
|
||||
|
@ -169,6 +210,11 @@ return require('packer').startup(function(use)
|
|||
requires = { {'nvim-lua/plenary.nvim'} },
|
||||
config = function()
|
||||
require('telescope').setup()
|
||||
|
||||
vim.keymap.set('n', '<leader>ff', '<cmd>Telescope find_files theme=dropdown<cr>', { noremap = true })
|
||||
vim.keymap.set('n', '<leader>fg', '<cmd>Telescope live_grep theme=dropdown<cr>', { noremap = true })
|
||||
vim.keymap.set('n', '<leader>fb', '<cmd>Telescope buffers theme=dropdown<cr>', { noremap = true })
|
||||
vim.keymap.set('n', '<leader>fd', '<cmd>Telescope builtin theme=dropdown<cr>', { noremap = true })
|
||||
end
|
||||
}
|
||||
-- ===
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
-- ===
|
||||
-- Configure the on_attach function that defines keymaps
|
||||
-- ===
|
||||
local lspconfig = require('lspconfig')
|
||||
|
||||
local opts = { noremap = true, silent = true }
|
||||
|
@ -37,3 +40,10 @@ for _, lsp in pairs(servers) do
|
|||
on_attach = on_attach
|
||||
}
|
||||
end
|
||||
-- ===
|
||||
|
||||
-- ===
|
||||
-- Colorscheme
|
||||
-- ===
|
||||
vim.cmd('colorscheme dracula')
|
||||
-- ===
|
||||
|
|
|
@ -108,7 +108,7 @@ local config = {
|
|||
use_async = true,
|
||||
use_autocomplete = 0,
|
||||
use_bufkill = true,
|
||||
use_buftabline = true,
|
||||
use_buftabline = false,
|
||||
use_clang_format = false,
|
||||
use_coc = false,
|
||||
use_comfortable_motion = false,
|
||||
|
@ -130,6 +130,7 @@ local config = {
|
|||
use_rust = true,
|
||||
use_sound = false,
|
||||
use_sxhkd = true,
|
||||
use_tabline = true,
|
||||
use_templator = false,
|
||||
use_utf8 = true,
|
||||
use_vimtex = true,
|
||||
|
@ -193,11 +194,5 @@ vim.cmd([[
|
|||
]])
|
||||
-- ===
|
||||
|
||||
-- ===
|
||||
-- Colorscheme
|
||||
-- ===
|
||||
vim.cmd('colorscheme dracula')
|
||||
-- ===
|
||||
|
||||
--vim.cmd("hi LineNr guifg=#B0BEC5")
|
||||
--vim.cmd("hi CursorLineNr guifg=#64FFDA")
|
||||
|
|
Loading…
Reference in New Issue