Change some more stuff with filename component

- Special case for git commit files
- Move to single quotes for consistency
master
Drake 2 years ago
parent 2259f1373f
commit 79fa0e14c3

@ -52,9 +52,11 @@ vim.cmd('COQnow -s')
local function filenameIfFileOpened() local function filenameIfFileOpened()
local filename = vim.fn.expand('%:t') local filename = vim.fn.expand('%:t')
if filename == '' then if filename == '' then
return "" return ''
elseif filename == 'COMMIT_EDITMSG' then
return '[Git commit]'
elseif vim.bo.modified then elseif vim.bo.modified then
return filename .. "*" return filename .. '*'
else else
return filename return filename
end end

Loading…
Cancel
Save