Adds new plugins to notes
This commit is contained in:
parent
379fa8a066
commit
fb07d396e8
4 changed files with 26 additions and 7 deletions
|
|
@ -45,11 +45,19 @@ vim.api.nvim_create_autocmd("VimLeavePre", {
|
|||
|
||||
vim.api.nvim_create_autocmd("VimEnter", {
|
||||
callback = function()
|
||||
print("Updating...")
|
||||
local command = "git pull --rebase --quiet --no-edit &> /dev/null"
|
||||
local pullSuccess = os.execute(command)
|
||||
if pullSuccess > 0 then
|
||||
os.execute(command)
|
||||
end
|
||||
vim.defer_fn(function()
|
||||
local command = "git pull --rebase --quiet --no-edit &> /dev/null"
|
||||
local pullSuccess = os.execute(command)
|
||||
if pullSuccess == 256 then
|
||||
vim.notify("Conflicts found. Please resolve and continue rebase", "error", {
|
||||
title = "Updating...",
|
||||
})
|
||||
return
|
||||
end
|
||||
|
||||
vim.notify("Pull success", "info", {
|
||||
title = "Updating...",
|
||||
})
|
||||
end, 100)
|
||||
end,
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue