feat(nvim): add keybind to sync packer
This commit is contained in:
parent
56d41d10b6
commit
9001cec9c2
@ -106,3 +106,19 @@ map('n', '<leader>sr', '', {
|
|||||||
map('v', '<leader>sr', '', {
|
map('v', '<leader>sr', '', {
|
||||||
callback = run_snip
|
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
|
||||||
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user