update prompt format nvim
This commit is contained in:
parent
34b3e87a57
commit
01675eb8fe
|
@ -3,13 +3,9 @@ local icons = require("config.icons")
|
|||
|
||||
function M.set_title()
|
||||
local title = " %t"
|
||||
local f = io.popen([[zsh -c '
|
||||
source $XDG_CONFIG_HOME/zsh/configs/autogenerated/hashes
|
||||
print -Pn "$USER@$HOST [%3~] "
|
||||
']])
|
||||
local f = io.popen([[ zsh -lc 'print -P $PS1' | sed 's/\[[0-9;]*m//g;s/» / %t/g' ]])
|
||||
if f ~= nil then
|
||||
title = f:read("*a") or ""
|
||||
title = title .. " %t"
|
||||
f:close()
|
||||
end
|
||||
vim.opt.titlestring = title
|
||||
|
|
Loading…
Reference in New Issue