Compare commits

..

4 commits

Author SHA1 Message Date
2b1f817f2b
feat: Switch to alpha.nvim 2024-11-30 11:08:42 -08:00
11c520863a
feat: Dashboard.nvim
Might switch to alpha tho
2024-11-30 11:08:18 -08:00
75a8915db4
feat: Set up the dev shell 2024-11-30 11:08:18 -08:00
573e24df9b
feat: Finish Snacks config 2024-11-29 20:19:17 -08:00
9 changed files with 114 additions and 7 deletions

15
Justfile Normal file
View file

@ -0,0 +1,15 @@
alias t := test
test:
git aa && nix run .
alias to := testone
testone:
git aa && nix run . -- flake.nix
alias tt := testtwo
testtwo:
git aa && nix run . -- flake.nix .stylua.toml
alias s := search
search this:
nh search {{this}}

View file

@ -51,16 +51,15 @@
shell = pkgs.mkShell {
name = "nvim-devShell";
buildInputs = with pkgs; [
# Tools for Lua and Nix development, useful for editing files in this repo
lua-language-server
nixd
alejandra
stylua
luajitPackages.luacheck
fish
just
];
shellHook = ''
# symlink the .luarc.json generated in the overlay
ln -fs ${pkgs.nvim-luarc-json} .luarc.json
# use fish
exec fish
'';
};
in {

View file

@ -33,8 +33,12 @@ with final.pkgs.lib; let
lz-n
snacks-nvim
# Util
plenary-nvim
# UI
mini-icons
alpha-nvim
bufferline-nvim
];

View file

@ -5,4 +5,9 @@ return {
Hint = '',
Info = '',
},
dashboard = {
quit = '',
mru = '',
project = '',
},
}

View file

@ -0,0 +1,53 @@
return {
'alpha-nvim',
before = function()
require('lz.n').trigger_load('plenary.nvim')
require('lz.n').trigger_load('mini.icons')
end,
after = function()
local theta = require('alpha.themes.theta')
local header = [[
]]
theta.header.val = vim.split(header, '\n')
local button = require('alpha.themes.dashboard').button
theta.buttons.val = {
{
type = 'text',
val = 'Shortcuts',
opts = { hl = 'SpecialComment', position = 'center' },
},
{ type = 'padding', val = 1 },
button(
'f',
'󰈞 Find file',
'<CMD>lua require("telescope").builtin.fd()<CR>'
),
button(
'g',
' Live grep',
'<CMD>lua require("telescope").builtin.live_grep()<CR>'
),
button(
's',
' Restore session',
'<CMD>lua require("persistence").load()<CR>'
),
button('q', ' Quit', '<CMD>qa<CR>'),
}
require('alpha').setup(theta.config)
end,
}

View file

@ -1,6 +1,7 @@
local req = require('lib.marleyvim').localRequire('plugins.ui')
return {
req('alpha-nvim'),
req('bufferline-nvim'),
req('mini-icons'),
}

View file

@ -0,0 +1,5 @@
local req = require('lib.marleyvim').localRequire('plugins.util')
return {
req('plenary'),
}

View file

@ -0,0 +1,4 @@
return {
'plenary.nvim',
lazy = true,
}

View file

@ -5,9 +5,30 @@ local lazyvim_root = require('lib.lazyvim.root')
require('snacks').setup({
bigfile = { enabled = true },
dashboard = { enabled = true },
notifier = { enabled = true },
quickfile = { enabled = true },
statuscolumn = { enabled = true },
words = { enabled = true },
})
-- Debuggers -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
_G.dd = function(...)
Snacks.debug.inspect(...)
end
_G.bt = function()
Snacks.debug.backtrace()
end
vim.print = _G.dd
-- Notifier -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
set({ 'n' }, '<LEADER>un', function()
Snacks.notifier.hide()
end, { desc = 'Dismiss all notifications' })
-- Buffers -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
set({ 'n' }, '<LEADER>bd', function()
Snacks.bufdelete()