diff --git a/init.lua b/init.lua index e8239ac..26bc72e 100644 --- a/init.lua +++ b/init.lua @@ -16,45 +16,48 @@ vim.opt.rtp:prepend(lazypath) -- Setup the package manager with plugins and configuration options require("lazy").setup({ + -- Default theme + "devraza/kagayaki.nvim", + "folke/which-key.nvim", - "nvim-telescope/telescope.nvim", + { + "nvim-telescope/telescope.nvim", + dependencies = { 'nvim-lua/plenary.nvim' }, + }, "neovim/nvim-lspconfig", "romgrk/barbar.nvim", "nvim-lualine/lualine.nvim", - "devraza/particle.nvim", - {"ellisonleao/glow.nvim", config = true, cmd = "Glow"}, - "rktjmp/lush.nvim", { - "nvimdev/dashboard-nvim", + "NeogitOrg/neogit", dependencies = { - "nvim-tree/nvim-web-devicons", "nvim-lua/plenary.nvim", - } + "sindrets/diffview.nvim", + "nvim-telescope/telescope.nvim", + }, + config = true }, + {"ellisonleao/glow.nvim", config = true, cmd = "Glow"}, { + "max397574/better-escape.nvim", + config = function() + require("better_escape").setup() + end, + }, + "rktjmp/lush.nvim", + { "nvim-treesitter/nvim-treesitter", version = false, build = ":TSUpdate", opts = { highlight = { enable = true }, indent = { enable = true }, - ensure_installed = { - "bash", - "diff", - "html", - "json", - "lua", - "markdown", - "python", - "rust", - "go", - "regex", - "toml", - "vim", - "yaml", - }, + ensure_installed = "maintained", } - } + }, + { + 'goolord/alpha-nvim', + dependencies = { 'nvim-tree/nvim-web-devicons' }, + }; }) -- Imports from files diff --git a/lua/core/dashboard.lua b/lua/core/dashboard.lua index d351dbd..ec22442 100644 --- a/lua/core/dashboard.lua +++ b/lua/core/dashboard.lua @@ -1,14 +1,62 @@ -require("dashboard").setup({ - theme = 'hyper', - config = { - header = { - " quark.nvim", - "", - }, - shortcut = { - { desc = 'Update', group = '@property', action = 'Lazy update', key = 'u' }, - { desc = 'Files', group = '@property', action = 'Telescope find_files', key = 'f' }, - }, - footer = {}, - }, -}) +local alpha = require('alpha') +local dashboard = require('alpha.themes.dashboard') +local fn = vim.fn +local config = dashboard.config + +local marginTopPercent = 0.3 +local headerPadding = fn.max({2, fn.floor(fn.winheight(0) * marginTopPercent) }) + +local ascii = { + " ⣴⣶⣤⡤⠦⣤⣀⣤⠆ ⣈⣭⣿⣶⣿⣦⣼⣆ ", + " ⠉⠻⢿⣿⠿⣿⣿⣶⣦⠤⠄⡠⢾⣿⣿⡿⠋⠉⠉⠻⣿⣿⡛⣦ ", + " ⠈⢿⣿⣟⠦ ⣾⣿⣿⣷ ⠻⠿⢿⣿⣧⣄ ", + " ⣸⣿⣿⢧ ⢻⠻⣿⣿⣷⣄⣀⠄⠢⣀⡀⠈⠙⠿⠄ ", + " ⢠⣿⣿⣿⠈ ⣻⣿⣿⣿⣿⣿⣿⣿⣛⣳⣤⣀⣀ ", + " ⢠⣧⣶⣥⡤⢄ ⣸⣿⣿⠘ ⢀⣴⣿⣿⡿⠛⣿⣿⣧⠈⢿⠿⠟⠛⠻⠿⠄ ", + " ⣰⣿⣿⠛⠻⣿⣿⡦⢹⣿⣷ ⢊⣿⣿⡏ ⢸⣿⣿⡇ ⢀⣠⣄⣾⠄ ", + " ⣠⣿⠿⠛ ⢀⣿⣿⣷⠘⢿⣿⣦⡀ ⢸⢿⣿⣿⣄ ⣸⣿⣿⡇⣪⣿⡿⠿⣿⣷⡄ ", + " ⠙⠃ ⣼⣿⡟ ⠈⠻⣿⣿⣦⣌⡇⠻⣿⣿⣷⣿⣿⣿ ⣿⣿⡇ ⠛⠻⢷⣄ ", + " ⢻⣿⣿⣄ ⠈⠻⣿⣿⣿⣷⣿⣿⣿⣿⣿⡟ ⠫⢿⣿⡆ ", + " ⠻⣿⣿⣿⣿⣶⣶⣾⣿⣿⣿⣿⣿⣿⣿⣿⡟⢀⣀⣤⣾⡿⠃ ", +} + +local header = { + type = "text", + val = ascii, + opts = { + position = "center", + hl = "AlphaHeader", + }, +} + +local buttons = { + type = "group", + val = { + dashboard.button("SPC f f", "Find File "), + dashboard.button("SPC f g", "Find Word "), + dashboard.button("SPC f e", "Edit File "), + { type = 'padding', val = 1 }, + dashboard.button("SPC l u", "Update Plugins"), + }, + opts = { + spacing = 1, + }, +} + +local section = { + header = header, + buttons = buttons +} + +local config = { + layout = { + { type = 'padding', val = headerPadding }, + section.header, + { type = 'padding', val = 2 }, + section.buttons, + }, +} + +dashboard.opts = config + +alpha.setup(dashboard.opts) diff --git a/lua/core/init.lua b/lua/core/init.lua index 2880743..afd9386 100644 --- a/lua/core/init.lua +++ b/lua/core/init.lua @@ -1,2 +1,4 @@ require 'core.options' require 'core.dashboard' +require 'core.keybinds' +require 'core.lualine' diff --git a/lua/core/options.lua b/lua/core/options.lua index d6bc93d..4f8a2e4 100644 --- a/lua/core/options.lua +++ b/lua/core/options.lua @@ -34,6 +34,9 @@ o.relativenumber = true o.signcolumn = "yes" o.termguicolors = true +-- Fix rendering of ASCII +o.linespace = -1 + -- Do not wrap lines o.wrap = false