Exafunction / codeium.vim

Free, ultrafast Copilot alternative for Vim and Neovim

Home Page:https://codeium.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

i cant get the statusline thing working in neovim, using lualine...

daUnknownCoder opened this issue · comments

tried both of these in lualine:

          {
            function()
              vim.api.nvim_call_function("codeium#GetStatusString", {})
              vim.cmd([[set statusline+=\{…\}%3{codeium#GetStatusString()}]])
            end,
          },

i always get a text: "nil" while i am actively using this plugin

Add it in the desired section:

function()
	return vim.fn["codeium#GetStatusString"]()
end

If you want to disable the ON text, this is what I did:

{
	'vim.fn["codeium#GetStatusString"]()',
	fmt = function(str)
		if str == " ON" then
			return ""
		elseif str == " * " then
			return " 󰔟 "
		else
			return str
		end
	end,
},

@sergiornelas, your thing works, but i really wanted the codeium logo to come so i was trying this:

          {
            'vim.fn["codeium#GetStatusString"]()',
            fmt = function(str)
              if str == " ON" then
                return ""
              elseif str == " OFF" then
                return ""
              elseif str == " * " then
                return ""
              else
                return str
              end
            end,
          },

any thoughts?

i want the logo