{pkgs, ...}: {
extraPlugins = [
(pkgs.vimUtils.buildVimPlugin {
name = "silicon";
src = pkgs.fetchFromGitHub {
owner = "michaelrommel";
repo = "nvim-silicon";
rev = "9fe6001";
hash = "sha256-1BeJSpcmZeuIZXrbrxMKvaQBZn2TtsjrFXk26w2In+E=";
};
})
];
extraConfigLua = ''
require('nvim-silicon').setup({
font = "FiraCode Nerd Font Mono",
theme = "Solarized (light)",
background = "#FFFFFF00",
pad_horiz = 40,
pad_vert = 40,
no_window_controls = true,
line_offset = function(args)
return args.line1
end,
shadow_blur_radius = 24,
shadow_offset_x = 0,
shadow_offset_y = 0,
to_clipboard = true,
window_title = function()
return vim.fn.fnamemodify(
vim.api.nvim_buf_get_name(vim.api.nvim_get_current_buf()),
":t"
)
end,
output = function()
return "~/Pictures/" .. os.date("!%Y-%m-%dT%H-%M-%SZ") .. "_code.png"
end,
})
'';
keymaps = [
{
action="<cmd>lua require('nvim-silicon').clip()<CR>";
key = "<leader>sc";
options.desc = "silicon to clipboard";
}
{
action="<cmd>lua require('nvim-silicon').file()<CR>";
key = "<leader>sf";
options.desc = "silicon to file";
}
];
}