-
Notifications
You must be signed in to change notification settings - Fork 46
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
How to provide options_file for ycmd? #479
Comments
We don't have great support for custom options right now. You can look at BTW, my responses will be slow for the next week as I'm on vacation. |
I see that the file contains a lot of valuable options. I would really think that is more simple to configure server in client-independent way, rather than port all the options into emacs. So my idea is to pass a file path to emacs-ycmd that points to a JSON file with all necessary options. Then it can read the file add a value to Some options like |
Yes, this could work. We need to provide reasonable default behavior like we do now; I don't want to require people to make this file. But users could specify a file that we layer on top of these defaults. I probably won't have time to put into this for a while. Do you have the time to work on this?
I'm not sure if this will be a problem, though my instinct is that it won't be an issue. |
I have recently switched after 8 years of vim to emacs. I am still learning lisp and spend a lot of time trying researching Emacs. Though, I will try to do it someday, if no one is working on it. |
Welcome!
If you're interested in learning emacs lisp (which is both awful and very rewarding), this could be a good place to start. And I'd be happy to help you work through it. I don't think it would be very hard: a new variable for the user's options file, a check to see if that variable is set, and the code to merge their options into the default options. Right now, nobody that I know of is working on this, and you're the only person who has expressed interest in a feature like this. |
Add `ycmd-settings-json-filepath` - path to YCMD settings JSON file. YCMD accepts a json file where the server settings are set, including a one-time HMAC. The file is deleted after the server starts. As for now, emacs-ycmd was just creating a temporary file from some hard-coded/customizable values. Since those settings have to direct relation to emacs-ycmd, rather only to YCMD, it is good idea to keep it this way and just feed the file adding an HMAC value. That change will read the JSON file, insert HMAC and pass it to YCMD. Please, test it, feedback is appreciated, I will mainly test it on C/C++ and Go. That is supposed to solve abingham#472, abingham#479.
ycmd
has an option--options_file
that is a json file with a lot of helpful options? For every ycmd start it is suppose to be created once, because of an HMAC secret inside. How doesemacs-ycmd
is handling this? Can I provide a file with my custom options for this? Should I handle this manually in my emacs configuration: creating a temporary file from a template, and providing as an option toycmd-server-command
?The text was updated successfully, but these errors were encountered: