dashboard
This commit is contained in:
parent
37f5e00264
commit
9800cd3ff9
69
init.lua
69
init.lua
@ -171,6 +171,75 @@ require("lazy").setup({
|
|||||||
"tpope/vim-sleuth", -- Detect tabstop and shiftwidth automatically
|
"tpope/vim-sleuth", -- Detect tabstop and shiftwidth automatically
|
||||||
"neanias/everforest-nvim",
|
"neanias/everforest-nvim",
|
||||||
"L3MON4D3/LuaSnip",
|
"L3MON4D3/LuaSnip",
|
||||||
|
{
|
||||||
|
"nvimdev/dashboard-nvim",
|
||||||
|
lazy = false, -- As https://github.com/nvimdev/dashboard-nvim/pull/450, dashboard-nvim shouldn't be lazy-loaded to properly handle stdin.
|
||||||
|
opts = function()
|
||||||
|
local logo = [[
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⡀⠀⠀⠀⢀⣤⣤⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣀⡀⢀⣤⣶⣾⣷⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣶⣦⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣾⣿⣿⣿⣿⣿⠟⠛⠛⠛⢻⣿⣿⣿⣿⠟⠉⢻⣿⣿⣿⣿⣿⣿⣆⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⣴⣿⣿⡿⠛⢿⣿⣿⣷⠀⠀⠀⠈⠿⠿⠋⠀⠀⠀⠀⠙⢿⡿⠇⠈⠻⣿⣿⣷⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⢠⣿⣿⣿⡟⠁⠀⠀⠙⠛⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⣀⠀⠀⠀⣠⢤⣜⣿⣿⣿⣷⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⢰⣿⡿⠟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠠⠴⠒⠒⠒⠒⠿⢭⣙⠓⠶⣟⠳⡞⠀⠻⣿⣿⣯⣦⠖⠴⣤⡀⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠠⡟⠀⠀⠀⢀⣠⡤⠴⠒⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢉⡷⠄⠈⣹⣅⠀⠀⣿⡟⣿⢧⣤⣀⠀⠙⣦⡀⠀
|
||||||
|
⠀⠀⠀⠀⠀⡀⣾⠇⠀⠰⠚⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⡴⠋⣀⡤⠖⣿⠈⣡⣾⡿⣜⢯⡻⣜⢿⣻⢶⣼⣶⡀
|
||||||
|
⠀⠀⣀⡴⠗⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⠚⠋⠁⠀⠀⠘⠋⠁⠀⠙⢿⣞⡽⣹⢮⡳⣏⡾⣽⡇
|
||||||
|
⠀⡼⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣻⣽⢣⡟⣵⡻⡼⡿⠀
|
||||||
|
⣼⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢰⣟⡮⢯⣽⢺⡵⣻⠗⠀
|
||||||
|
⡏⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⡿⣏⢾⣏⡞⣧⢟⣿⠃⠀
|
||||||
|
⣧⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣿⡝⣞⣳⢮⡽⣞⣽⡿⠀⠀
|
||||||
|
⢸⣆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⣤⡾⣗⢯⡽⣎⡷⣝⡮⣿⠃⠀⠀
|
||||||
|
⠀⠚⢦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣤⡶⣿⢻⡭⣗⢯⢾⣱⡻⣼⢣⣟⣿⠀⠀⠀
|
||||||
|
⠀⠀⠀⠙⠶⣤⣀⡀⠀⠀⠀⠀⠴⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣀⣠⣤⣤⣶⢾⡟⣯⢳⡽⣚⣧⢟⣮⣛⡮⢷⣹⢧⡟⣾⣇⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠈⠋⠛⠒⠲⠶⠶⣤⣤⣴⢶⡶⣶⢶⡶⡿⣟⢿⣫⢟⣮⢳⣝⡮⣽⢺⡝⣾⡹⣎⡟⡶⣭⣛⡧⣟⢮⡽⣽⡏⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢰⣿⣻⢼⣣⠿⣜⣧⢻⡵⣛⣮⢗⡯⣞⡽⣎⢷⡭⢷⣫⢷⡹⢧⣻⡝⣶⢫⢷⣹⡞⣵⢯⣿⠀⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⢧⣻⢼⣿⣝⢮⡗⣯⣝⢮⣻⢼⣣⠿⣜⡯⣞⣻⢼⣣⢟⣯⢳⡽⣺⢭⢷⣣⢟⣮⢳⢿⡇⠀⠀
|
||||||
|
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⢧⣛⢾⣿⡞⣧⢟⡾⣜⢯⡞⣧⢏⡿⣱⣻⡜⣧⡟⣼⣫⢞⣧⢻⡵⣛⣮⢗⡯⣞⣭⢟⣿⠀⠀
|
||||||
|
]]
|
||||||
|
|
||||||
|
logo = string.rep("\n", 8) .. logo .. "\n\n"
|
||||||
|
local utils = require("dashboard.utils")
|
||||||
|
local mlist = utils.get_mru_list()
|
||||||
|
local opts = {
|
||||||
|
theme = "hyper",
|
||||||
|
hide = {
|
||||||
|
-- this is taken care of by lualine
|
||||||
|
-- enabling this messes up the actual laststatus setting after loading a file
|
||||||
|
statusline = true,
|
||||||
|
tabline = true,
|
||||||
|
winbar = true,
|
||||||
|
},
|
||||||
|
config = {
|
||||||
|
shortcut = {
|
||||||
|
{ desc = "さようなら、バイバイ、いなり寿司。" },
|
||||||
|
},
|
||||||
|
header = vim.split(logo, "\n"),
|
||||||
|
packages = { enable = false },
|
||||||
|
project = { enable = false },
|
||||||
|
mru = { enable = true, limit = 10, label = "最近使ったファイル:", cwd_only = false },
|
||||||
|
footer = function()
|
||||||
|
return { "" }
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
-- open dashboard after closing lazy
|
||||||
|
if vim.o.filetype == "lazy" then
|
||||||
|
vim.api.nvim_create_autocmd("WinClosed", {
|
||||||
|
pattern = tostring(vim.api.nvim_get_current_win()),
|
||||||
|
once = true,
|
||||||
|
callback = function()
|
||||||
|
vim.schedule(function()
|
||||||
|
vim.api.nvim_exec_autocmds("UIEnter", { group = "dashboard" })
|
||||||
|
end)
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
|
return opts
|
||||||
|
end,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"3rd/image.nvim",
|
"3rd/image.nvim",
|
||||||
build = false, -- so that it doesn't build the rock https://github.com/3rd/image.nvim/issues/91#issuecomment-2453430239
|
build = false, -- so that it doesn't build the rock https://github.com/3rd/image.nvim/issues/91#issuecomment-2453430239
|
||||||
|
Loading…
x
Reference in New Issue
Block a user