简体   繁体   中英

Where is the definition for a new Python interpreter in Eclipse Pydev stored?

I'm using Eclipse Luna Service Release 2 (4.4.2), with PyDev 4.0.0, on Windows 7. I've recently installed Anaconda 2.4.0 to use as my Python interpreter. I've configured a new "Anaconda2" Python interpreter in Eclipse, and modified my project settings to use this new interpreter.

I'd like to commit my modified project file to source control, so that colleagues can take advantage of the update. I can see that .pydevproject has been modified, but when I look at the changes, it simply specified that "Anaconda2" is the interpreter to be used with the project.

For this to be useful to others, they'll presumably also need my definition of what the "Anaconda2" interpreter actually is (ie the path to the Python executable). However, I can't find where this definition is stored. I've looked in my project directory, in the Eclipse installation directory (C:\\eclipse) and in the Windows Registry, with no success.

Where is this information stored, so that I can share the updated file with colleagues, rather than leaving them needing to manually set up the interpreter themselves?

(Assume that we have a standard development environment, so that everyone will have Anaconda installed to the same location on their hard drive.)

Well, usually the default way of operating would be not committing files with a named interpreter, rather leave it empty and let it use the one that's configured for the user.

Now, having said that, there are scenarios where it may be useful to commit a named interpreter, but it's usually if you're within a company that has standardized say a Python2 and a Python3 interpreter and a given project is dependent only on one of those (then it may make sense standardizing that), but usually the default is leaving empty and letting each user configure its own Python interpreter.

On a side note, if you wanted to have the same interpreter for everyone, it's possible to have a plugin which would do that inside PyDev, although that'd require creating a plugin inside Eclipse (although it should be relatively straightforward).

The question has been answered by greg-449, in a comment:

This says the info is in the workspace .metadata/.plugins/org.python.pydev folder.

Which means I'm not going to be able to share the configuration with colleagues; they'll have to manually modify their projects themselves.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM