add secret generatiopn function

This commit is contained in:
Alexander Navarro 2026-01-07 11:51:14 -03:00
parent 6fa42a7c2d
commit fca513c15a

View file

@ -9,3 +9,11 @@ vim.api.nvim_create_user_command("SopsEncrypt", function(args)
end, { end, {
desc = "Decrypt current file with sops", desc = "Decrypt current file with sops",
}) })
vim.api.nvim_create_user_command("Secret", function(args)
local response = vim.system({ "openssl", "rand", "-base64", "32" }, { text = true }):wait()
vim.api.nvim_paste(vim.trim(response.stdout), false, -1)
end, {
desc = "Generate secret",
})