feat(nvim): add keybind to sync packer

This commit is contained in:
Price Hiller 2022-05-09 17:37:21 -05:00
parent 56d41d10b6
commit 9001cec9c2

View File

@ -106,3 +106,19 @@ map('n', '<leader>sr', '', {
map('v', '<leader>sr', '', {
callback = run_snip
})
-- Packer Mappings
local packer_sync = function ()
async.run(function ()
vim.notify.async('Syncing packer.', 'info', {
title = 'Packer'
})
end)
local snap_shot_time = os.date("!%Y-%m-%dT%TZ")
vim.cmd('PackerSnapshot ' .. snap_shot_time)
vim.cmd('PackerSync')
end
map('n', '<leader>ps', '', {
callback = packer_sync
})