Giter Club home page Giter Club logo

pythonhelper's Introduction

Pythonhelper

This was a mirror of http://www.vim.org/scripts/script.php?script_id=435.

This Vim plugin helps in Python development by placing a name of current class, method or function under the cursor on the status line in normal and insert mode.

Installation

To use this plugin either +python or +python3 feature compiled in vim is required. To check it, issue :version in vim instance and look for python entries.

To install it, any kind of Vim package manager can be used, like NeoBundle, Pathogen, Vundle or vim-plug.

For manual installation, copy subdirectories from this repository to your ~/.vim directory.

Next, place one of the available functions either on your .vimrc:

set statusline=[....]\ %{TagInStatusLine()}\ [.....]

or under ~/.vim/ftplugin/python/your_file.vim:

setlocal statusline=[....]\ %{TagInStatusLine()}\ [.....]

Functions, which may be placed on the status line are as follows:

  • TagInStatusLine - shows name and type of the tag, i.e.:

    ClassName.some_method_name (method)
    
  • TagInStatusLineTag - shows only the name:

    ClassName.some_method_name
    
  • TagInStatusLineType - shows only the tag type:

    method
    

Restart vim, and you all set.

Changelog

Version Date Author Notes
1.1 2016-12-10 Roman Dobosz Fixed python3 enabled vim (without python2)
1.0 2016-05-30 Roman Dobosz Rewrite python part (simplifying the code, clean it up, separate from vimscript, add some tests), make it Python3 compatible, lots of other changes
  2012-02-12 cheater Several bug fixes, code cleanup, docs update
  2010-02-13 Oluf Lorenzen Updated the way how to display information on status line
0.83 2010-01-04 Michal Vitecek Added support for the CursorHoldI event so that the class/method/function is recognized also in Insert mode
0.82 2009-07-10 Michal Vitecek fixed a bug when nested functions/classes were not properly detected
0.81 2003-03-13 Michal Vitecek fixed a small bug in indent level recognition
0.80 2002-10-18 Michal Vitecek removed the dependency on exuberant ctags which parsed the python source code wrongly anyways. From now on only VIM with python support is needed. This might greatly help windoze users.
0.72 2002-10-03 Michal Vitecek fixed problem with parsing ctags output on python files that use tabs when there is a syntax error in the file and ctags parses it incorrectly a warning is displayed in the command line
0.71 2002-10-02 Michal Vitecek fixed problem with undefined window-bound variable w:PHStatusLine when a window has been split into two. unbound event BufWinEnter because it's not needed because of the above change now
0.70 2002-10-02 Michal Vitecek Initial upload

License

Originally, there was no licence whatsoever, so I've put it under under 3-clause BSD license. See LICENSE file for details.

pythonhelper's People

Contributors

cheater avatar finkregh avatar gryf avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.