There are a number of Vim plugins to show the current Python class and method name or function name (e.g., this). However, they can be extremely "heavy" (the linked example requires Vim compiled with Python, and is pretty slow when indexing a large Python file) and moreover, all seem to be geared to showing the information dynamically in the status bar. While the latter might be desirable in some contexts, the required binding to a CursorHold trigger coupled with the slowness in indexing, make it clumsy to use when navigating large files. Sometimes, all that is wanted or needed is an "on-demand" brief display of the information. The following code takes care of this. When sourced into your Vim session, it echos the current Python class and method name or function name when invoked via "<Leader>?" or ":EchoPythonLocation".
Monte hates being separated from Carlo, and he quickly works himself into a desperate and distraught frenzy trying to get back to him.
This morning, Monte slipped into the bathroom without me noticing just as I was leaving, and I accidentally ended up locking him in. I got back at lunch and did not notice anything very amiss, except for the fact that while Carlo trotted up to greet me as usual, Monte did not. Then the scratching/tearing sounds coming from the bathroom. I think that given another a hour or so he would have made it all the way through.
There are a number of solutions for executing Python code in your active buffer in Vim.
All of these expect the buffer lines to be well-formatted Python code, with correct indentation.
Many times, however, I am working on program or other documentation (in, for example reStructuredTex or Markdown format), and the code fragments that I want to execute have extra indentation or line leaders.
Headless guests are usually not the best company for conversation, no matter how fancy the moves they might pull off on the dance floor.
However, a headless virtual guest machine running Linux makes for a fantastic development environment, serving as a back-end "under-the-hood" engine to crunch and execute code.
This is especially useful if your primary host ecosystem has gradually become more and more irritating for development with every operating system release (yes, Apple, I am looking at you).
This post assumes that you have already done a basic install of a Arch Linux guest machine under VMware. The following describes the basic and minimal steps that I took so as to allow this machine to function as a headless virtual guest that would have access to the host filesystem and allow SSH logins from the host (the configuration of the virtualization platform and the host for this setup is described here).
SciPy and Numpy are great packages for scientific computing.
Unfortunately, installation on Mac OS X 10.7 Lion is not a very smooth affair.
It can be a pain for moderately-experienced developers, and a nightmare for novice end-users.