-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.lua
More file actions
53 lines (44 loc) · 1.13 KB
/
init.lua
File metadata and controls
53 lines (44 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
-- Vimscriptコマンドを実行するためのヘルパー関数
local function cmd(command)
vim.cmd(command)
end
vim.opt.termguicolors = true
-- 各設定ファイルの読み込み
local function source(file)
cmd('source ' .. file)
end
-- 条件付きファイル読み込み
local function source_if_exists(file)
local expanded_file = vim.fn.expand(file)
if vim.fn.filereadable(expanded_file) == 1 then
source(expanded_file)
end
end
require('basic')
require('indent')
require('search')
require('moving')
require('edit')
require('encoding')
require('hack')
if not vim.g.vscode then
require('completion')
require('terminal')
end
source_if_exists('~/nvim_local.vim')
source_if_exists('~/dotfiles_private/nvim_local.vim')
-- プラグイン設定
require("config.lazy")
-- カラースキーム
require('color')
require('apperance')
-- gh openpr: カレント行のblameからPRを開く
local ok, gh_openpr = pcall(require, "gh_openpr")
if ok then
vim.keymap.set(
"n",
"<leader>gp",
gh_openpr.open_pr_from_current_line,
{ desc = "Open PR for current line via gh openpr", silent = true }
)
end