1
0
mirror of https://github.com/jiriks74/presence.nvim synced 2024-12-05 01:19:01 +01:00

feat: oil working with git buttons

This commit is contained in:
nick22985 2024-05-11 02:28:03 +10:00
parent aaaed3d01e
commit a86c5e3bc5
No known key found for this signature in database
GPG Key ID: EDEE4CC55CB599FF

@ -724,6 +724,10 @@ end
-- Get either user-configured buttons or the create default "View Repository" button definition
function Presence:get_buttons(buffer, parent_dirpath)
if parent_dirpath ~= nil and parent_dirpath:find("^oil://") then
parent_dirpath = parent_dirpath:gsub("oil://", "")
end
-- User configured a static buttons table
if type(self.options.buttons) == "table" then
local is_plural = #self.options.buttons > 1