Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE REQUEST] being able to source intelephense.licenceKey from somewhere else (another file, env var, etc) #59

Open
Nemoden opened this issue Apr 14, 2020 · 2 comments
Assignees

Comments

@Nemoden
Copy link

Nemoden commented Apr 14, 2020

A quick naive search on github using a query “intelephense.licenceKey” reveals the problem very soon - people committing their keys into the version control.
Would be nice to have intelephense.licenceKeyFile or intelephense.licenceKeyEnvVar to stop this from happening.
While it’s not implemented, how do I safely store the key if I still want to commit my coc-settings.json?

@Nemoden
Copy link
Author

Nemoden commented Apr 15, 2020

Solved the issue with:

if filereadable(expand("~/.vim/coc-user-config.vim"))
  source ~/.vim/coc-user-config.vim
endif

added ~/.vim/coc-user-config.vim to .gitignore, contents:

let g:coc_user_config = {
            \ "intelephense.licenceKey": "REAL_LICENCE_KEY",
            \ }

But this method is not as good as if main page of coc-phpls might have suggested a more straightforward, and fool-proof approach. Right now, as I noticed, search on github "intelephense.licenceKey" and see how many people blindly copy-pasted and committed their actual keys to github.

@yaegassy
Copy link
Contributor

@Nemoden Hi,

In the current version of intelephense, you can load the license key from a file.
Please check for similar closed issues. #51

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants