1
0
mirror of https://github.com/jdhao/nvim-config.git synced 2025-06-08 14:14:33 +02:00

Compare commits

...

8 Commits

Author SHA1 Message Date
jdhao
2c7e4aa87a
Merge pull request #123 from jdhao/repolink
update repo link for transferred plugins
2022-09-29 00:00:12 +08:00
jdhao
07dd60206b update repo link for transferred plugins 2022-09-28 23:57:36 +08:00
jdhao
c3d4eb371b
Merge pull request #122 from jdhao/opt
always use sign column
2022-09-28 23:40:12 +08:00
jdhao
597a2aba80 always use sign column 2022-09-28 23:39:09 +08:00
jdhao
f1f6d0b351
Merge pull request #121 from jdhao/clean
remove config for unused plugins
2022-09-28 23:37:54 +08:00
jdhao
e1930ba153 remove config for unused plugins
vim-signify, vim-startify
2022-09-28 23:36:44 +08:00
jdhao
a8db734e75
Merge pull request #120 from jdhao/firenvim
update conf related to firenvim
2022-09-28 23:32:48 +08:00
jdhao
4026baef19 update conf related to firenvim
1. Change autocmd for buffers started by firenivm, it seems that
   BufNewFile does not work as intended, in contrast, BufEnter, BufRead,
   BufWinEnter seem to work.
2. Disable several plugins if we are using firenvim, these plugins
   include dashboard-nvim, lualine, bufferline.nvim
2022-09-28 23:22:23 +08:00
4 changed files with 28 additions and 25 deletions

View File

@ -58,7 +58,7 @@ and how to set up on different platforms (Linux, macOS, and Windows).
+ Code, snippet, word auto-completion via [nvim-cmp](https://github.com/hrsh7th/nvim-cmp).
+ Language server protocol (LSP) support via [nvim-lspconfig](https://github.com/neovim/nvim-lspconfig).
+ Git integration via [vim-fugitive](https://github.com/tpope/vim-fugitive).
+ Better escaping from insert mode via [better-escape.vim](https://github.com/jdhao/better-escape.vim).
+ Better escaping from insert mode via [better-escape.vim](https://github.com/nvim-zh/better-escape.vim).
+ Ultra-fast project-wide fuzzy searching via [LeaderF](https://github.com/Yggdroot/LeaderF).
+ Faster code commenting via [vim-commentary](https://github.com/tpope/vim-commentary).
+ Faster matching pair insertion and jump via [delimitMate](https://github.com/Raimondi/delimitMate).
@ -75,7 +75,7 @@ and how to set up on different platforms (Linux, macOS, and Windows).
+ Code highlighting via [nvim-treesitter](https://github.com/nvim-treesitter/nvim-treesitter).
+ Code editing using true nvim inside browser via [firenvim](https://github.com/glacambre/firenvim).
+ Beautiful colorscheme via [sainnhe/gruvbox-material](https://github.com/sainnhe/gruvbox-material) and other colorschemes.
+ Markdown writing and previewing via [vim-markdown](https://github.com/plasticboy/vim-markdown) and [markdown-preview.nvim](https://github.com/iamcco/markdown-preview.nvim).
+ Markdown writing and previewing via [vim-markdown](https://github.com/preservim/vim-markdown) and [markdown-preview.nvim](https://github.com/iamcco/markdown-preview.nvim).
+ LaTeX editing and previewing via [vimtex](https://github.com/lervag/vimtex) <sup id="a1">[1](#f1)</sup>.
+ Animated GUI style notification via [nvim-notify](https://github.com/rcarriga/nvim-notify).
+ Smooth scroll experience via [neoscroll](https://github.com/karb94/neoscroll.nvim).

View File

@ -162,7 +162,7 @@ set termguicolors
" https://github.com/neovim/neovim/wiki/FAQ#how-to-change-cursor-color-in-the-terminal
set guicursor=n-v-c:block-Cursor/lCursor,i-ci-ve:ver25-Cursor2/lCursor2,r-cr:hor20,o:hor20
set signcolumn=auto:2
set signcolumn=yes:1
" Remove certain character from file name pattern matching
set isfname-==

View File

@ -182,14 +182,7 @@ let g:neoformat_c_clangformat = {
let g:neoformat_enabled_cpp = ['clangformat']
let g:neoformat_enabled_c = ['clangformat']
"""""""""""""""""""""""""vim-signify settings""""""""""""""""""""""""""""""
" The VCS to use
let g:signify_vcs_list = [ 'git' ]
" Change the sign for certain operations
let g:signify_sign_change = '~'
"""""""""""""""""""""""""plasticboy/vim-markdown settings"""""""""""""""""""
"""""""""""""""""""""""""vim-markdown settings"""""""""""""""""""
" Disable header folding
let g:vim_markdown_folding_disabled = 1
@ -311,11 +304,6 @@ if ( g:is_win || g:is_mac ) && executable('latex')
endif
endif
""""""""""""""""""""""""""""vim-startify settings""""""""""""""""""""""""""""
" Do not change working directory when opening files.
let g:startify_change_to_dir = 0
let g:startify_fortune_use_unicode = 1
""""""""""""""""""""""""""""vim-matchup settings"""""""""""""""""""""""""""""
" Improve performance
let g:matchup_matchparen_deferred = 1
@ -362,16 +350,20 @@ if exists('g:started_by_firenvim') && g:started_by_firenvim
\ }
\ }
function! s:setup_firenvim() abort
set noruler noshowcmd
set laststatus=0 showtabline=0
function s:setup_firenvim() abort
set signcolumn=no
set noruler
set noshowcmd
set laststatus=0
set showtabline=0
endfunction
augroup firenvim
autocmd!
autocmd FileType text call s:setup_firenvim()
autocmd BufNewFile github.com_*.txt set filetype=markdown
autocmd BufNewFile stackoverflow.com_*.txt set filetype=markdown
autocmd BufEnter * call s:setup_firenvim()
autocmd BufEnter sqlzoo*.txt set filetype=sql
autocmd BufEnter github.com_*.txt set filetype=markdown
autocmd BufEnter stackoverflow.com_*.txt set filetype=markdown
augroup END
endif

View File

@ -28,6 +28,11 @@ vim.cmd("packadd packer.nvim")
local packer = require("packer")
local packer_util = require("packer.util")
-- check if firenvim is active
local firenvim_not_active = function()
return not vim.g.started_by_firenvim
end
packer.startup {
function(use)
-- it is recommended to put impatient.nvim before any other plugins
@ -130,13 +135,19 @@ packer.startup {
use {
"nvim-lualine/lualine.nvim",
event = "VimEnter",
cond = firenvim_not_active,
config = [[require('config.statusline')]],
}
use { "akinsho/bufferline.nvim", event = "VimEnter", config = [[require('config.bufferline')]] }
use { "akinsho/bufferline.nvim", event = "VimEnter",
cond = firenvim_not_active,
config = [[require('config.bufferline')]] }
-- fancy start screen
use { "glepnir/dashboard-nvim", event = "VimEnter", config = [[require('config.dashboard-nvim')]] }
use { "glepnir/dashboard-nvim", event = "VimEnter",
cond = firenvim_not_active,
config = [[require('config.dashboard-nvim')]]
}
use {
"lukas-reineke/indent-blankline.nvim",
@ -236,7 +247,7 @@ packer.startup {
use { "kevinhwang91/nvim-bqf", ft = "qf", config = [[require('config.bqf')]] }
-- Another markdown plugin
use { "plasticboy/vim-markdown", ft = { "markdown" } }
use { "preservim/vim-markdown", ft = { "markdown" } }
-- Faster footnote generation
use { "vim-pandoc/vim-markdownfootnotes", ft = { "markdown" } }