Open erichlf opened 2 weeks ago
@erichlf are you referring to api keys given to old pro users?
Sorry I mean AUTH Token. I have corrected the description.
The auth token lives for 1 hour so this won't work. What other plugins do?
A nice workaround could be to mount ~/.config/TabNine
. Assuming you're logged-in in the host
That is good to know.
Does it work for you?
I have to figure out why when I bind mount the directory, or use it as a volume it becomes owned by root and I don't have permissions to do anything with it.
The issue is that ~/.config
doesn't already exist in the container and so when ~/.config/TabNine
is mounted it will then create the ~/.config
directory giving to root ownership, which then breaks all sorts of other things that I have going on that depends on that directory having non-root ownership. What I do as a workaround is that put the following in my dotfiles
setup script:
if [[ -d $HOME/.config && ! $(stat -c "%U" $HOME/.config) == "$(whoami)" ]]; then
sudo chown $UID $HOME/.config
fi
Once I got the permissions fixed then I was able to get neovim up and running and then I saw that tabnine was working.
Is your feature request related to a problem? Please describe. My development environment is in docker containers and so every time I restart a docker container I have to re-authorize tabnine. It would be nice if there could be an automated way to authorize the tabnine plugin.
Describe the solution you'd like Add the ability to supply an
auth_cmd
where the output of this command is a string containing the authorization token. I tend to store authorization tokens and api keys in gnu pass and so one possible command would bepass show tabnine/auth_token
. But this command could be anything that results in a string that is the auth token.Describe alternatives you've considered I would consider most anything that makes it where I don't have to manually enter the auth token. However, solutions like storing in an environment variable should be avoided.