自己流 init.vim(neovim)です。

```
" ↓ プラグインの記述はこの中に書く
call plug#begin()

" githubで公開されているプラグインは 作者名/リポジトリ名 で指定できる
Plug 'scrooloose/nerdtree'
Plug 'jistr/vim-nerdtree-tabs'

Plug 'tomasr/molokai'
"Miura
Plug 'vim-jp/vimdoc-ja'
Plug 'vimwiki/vimwiki'

Plug 'nvim-tree/nvim-web-devicons' " OPTIONAL: for file icons
Plug 'lewis6991/gitsigns.nvim' " OPTIONAL: for git status
Plug 'romgrk/barbar.nvim'

Plug 'MattesGroeger/vim-bookmarks'

"" Vim-Session
Plug 'xolox/vim-misc'
Plug 'xolox/vim-session'

call plug#end()

" Required:
filetype plugin indent on
"*****************************************************************************
" Basic Setup
"*****************************************************************************"
set noswapfile " スワップファイルも作成しない

" Encoding
set encoding=utf-8
set fileencoding=utf-8
set fileencodings=utf-8

" Fix backspace indent
set backspace=indent,eol,start

" Tabs. May be overridden by autocmd rules
set tabstop=4
set softtabstop=0
set shiftwidth=4
set expandtab

" Map leader to ,
let mapleader=' '

" Enable hidden buffers
set hidden

"" Searching
set hlsearch
set incsearch
set ignorecase
set smartcase

set fileformats=unix,dos,mac

if exists('$SHELL')
    set shell=$SHELL
else
    set shell=/bin/sh
endif

"*****************************************************************************
"" Visual Settings
"*****************************************************************************
syntax on
set ruler
" set number
set relativenumber

let no_buffers_menu=1
colorscheme molokai

" Better command line completion 
set wildmenu

" mouse support
set mouse=a

set mousemodel=popup
set t_Co=256
set guioptions=egmrti
set gfn=Monospace\ 10

"" NERDTree configuration
let g:NERDTreeChDirMode=2
let g:NERDTreeIgnore=['node_modules','\.rbc$', '\~$', '\.pyc$', '\.db$', '\.sqlite$', '__pycache__']
let g:NERDTreeSortOrder=['^__\.py$', '\/$', '*', '\.swp$', '\.bak$', '\~$']
let g:NERDTreeShowBookmarks=1
let g:nerdtree_tabs_focus_on_files=1
let g:NERDTreeMapOpenInTabSilent = '<RightMouse>'
let g:NERDTreeWinSize = 50
set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*.pyc,*.db,*.sqlite,*node_modules/
nnoremap <silent> <F2> :NERDTreeFind<CR>
nnoremap <silent> <F3> :NERDTreeToggle<CR>

" Wikiページファイルのディレクトリ： ~/my_site/
" HTMLファイルの出力先ディレクトリ： ~/public_html/
" let g:vimwiki_list = [{'path':'~/Programs/', 'path_html':'~/Programs/'}]
let g:vimwiki_list = [{'path': '~/Programs/',
                      \ 'syntax': 'markdown', 'ext': 'md'}]

let g:vim_markdown_folding_disabled = 1

" session management
let g:session_directory = "~/.config/nvim/session"
let g:session_autoload = "no"
let g:session_autosave = "no"
let g:session_command_aliases = 1

"*****************************************************************************
"" Mappings
"*****************************************************************************

"" Miura
"set foldmethod=indent
"au BufWinLeave
"au BufWinEnter

nnoremap <f5> :w<CR>
nnoremap <f6> ggVG
nnoremap <f7> :only<CR>
" nnoremap <f8> vi"

inoremap <C-h> <left>
inoremap <C-j> <down>
inoremap <C-k> <up>
inoremap <C-l> <right>

inoremap <C-f> <home>
inoremap <C-g> <end>
inoremap <C-d> <del>

inoremap <silent> dd <ESC>ddi
inoremap <silent> ii <ESC>o

"" Split
noremap <Leader>h :<C-u>split<CR>
noremap <Leader>v :<C-u>vsplit<CR>

"" Copy/Paste/Cut
if has('unnamedplus')
  set clipboard=unnamed,unnamedplus
endif

noremap YY "+y<CR>
noremap <leader>p "+gP<CR>
noremap XX "+x<CR>

"" Buffer nav
noremap <leader>z :bp<CR>
noremap <leader>x :bn<CR>
noremap <leader>c :bd<CR>

"" Clean search (highlight)
nnoremap <silent> <leader><space> :noh<cr>

" session management
nnoremap <leader>so :OpenSession<Space>
nnoremap <leader>ss :SaveSession<Space>
nnoremap <leader>sd :DeleteSession<CR>
nnoremap <leader>sc :CloseSession<CR>

" 新規タブでターミナルモードを起動
nnoremap <silent> tt <cmd>terminal<CR>
" 下分割でターミナルモードを起動
nnoremap <silent> tx <cmd>belowright new<CR><cmd>terminal<CR>

" ターミナルを開いたらに常にinsertモードに入る
autocmd TermOpen * :startinsert

tnoremap <ESC> <C-\><C-n>
tnoremap <C-W>n       <cmd>new<cr>
tnoremap <C-W>q       <cmd>quit<cr>
tnoremap <C-W>c       <cmd>close<cr>
tnoremap <C-W>o       <cmd>only<cr>

autocmd InsertLeave * :silent !fcitx-remote -c

```