EzDevInfo.com

SublimeRope

ST2 only, use SublimePythonIDE with ST3: Adds Python completions and some IDE-like functions to Sublime Text 2, through the use of the Rope library

ST2- Adding custom directory for Auto Completion (SublimeRope)

http://sublimerope.readthedocs.org/en/latest/cache_mechanisms.html

I want to add a custom directory from where I want auto completion. The Old Way mentioned on the above page does that job with prefs.add('python_path', '/home/abc/custom/') , but the page says it's not recommended.

How can I do add a custom directory (say /home/abc/custom/) with the newer way mentioned on the page? It only explains how to add modules not directories.


Source: (StackOverflow)

How can I change the built-in python in Sublime Text 2?

Questions like this: Change python interpreter - Sublime Text 2 are great for if you actually want to run Build against your Python code. However, I want plugins (such as SublimeRope) to run the Python of my choosing rather than the built-in Python, which happens to be 2.6

I work in Python 2.7, so the built-in Python 2.6 causes syntax errors to be raised often when trying to use SublimeRope.

I've found all sorts of ways to change the Python related to running code being worked on, but none that affect the Python used by the plugin.

I've been using:

import sys
print sys.version

in the plugin .py code to see what version is being run against it, and it's always the built-in 2.6

EDIT 1: I see there is a feature request into Sublime Text 2 to make Python 2.7 the embedded python: http://sublimetext.userecho.com/topic/105249-update-the-python-embedded-interpreter-to-27/ Please upvote that if there is no other way to do this.

EDIT 2: This issue for the plugin SublimeLinter is relevant: https://github.com/SublimeLinter/SublimeLinter/issues/13 Because of how that plugin is setup, it appears to be possible to use the system Python instead of the Sublime Text 2 embedded Python. I haven't been able to find an analogous way to change the Python used for the SublimeRope plugin.


Source: (StackOverflow)

Advertisements

How to configure sublimerope to auto complete python code?

I am trying to use sublime to write code, I want to know how to configure sublime so it can do auto-complete as eclipse does?

I have installed PyQt4, and it's ok if I use eclipse, if I write the following code: from PyQt4. After I input the dot, a list of possible matches will show in a drop-down list? how can I do this with sublimerope? I am using mac. Which configuration needs changed?


Source: (StackOverflow)

SublimeRope Autocompletions not working on Windows

I'm having trouble getting autocompletions to work for SublimeRope on Windows 8.

First, I noticed that SublimeRope messes up paths when creating a new Rope project on Windows, so I fixed the python_path prefs in .ropeproject > config.py, which are:

prefs.add('python_path', 'C:/Users/brandon/python_virtualenvs/aa/Lib/site-packages')
prefs.add('python_path', 'C:/Users/brandon/django_projects/andrews-app')

I've also tried specifying the packages to auto-import in my project file:

"rope_autoimport_modules": ["django.*"]

When I attempt to run: Rope: Regenerate Global Module Cache, I get an error:

"Missing modules in configuration file"

which Google has not been able to provide an answer for. Is anyone on Windows able to get SublimeRope working? I would really appreciate some help!


Source: (StackOverflow)