both: Pydiction
Pydiction allows you to implement the TAB code complement in Vim, which includes: standard, custom, and Third-party modules and packages. Plus keywords, bifs, and strings. Pydiction mainly consists of three parts: python_pydiction.vim– This file for vim plugin file, implementation of the Python file TAB full function complete-dict– the file for vim DiC Tionary file, which contains information such as Python keywords and module structures. Is the reference file that plugin is looking for when it is complete pydiction.py– the file is a Python script file that is used to generate dictionary files. You can add more TAB-complete module pydiction configuration by executing this script to place the Python_pydiction.vim under the Ftplugin folder, such as mine:
/usr/share/vim/vimfiles/ftplugin/python_pydiction.vim
To generate a dictionary file
Python pydiction.py django.db.models
# For example, put pydiction.py in the settings.py folder to execute the above command, more at the end of this article
Edit VIMRC file, add three lines of code
FileType plugin on
# Open plugin let
g:pydiction_location = '/path/to/your/complete-dict ' let
g:pydiction_menu_ Height =
# The dictionary file generated in the previous step:/data/www/xtyw/xtyw/complete-dict
# So the path above is it.
the use of Pydiction
tab auto complement, as shown in figure:
Finally, make up a dictionary of common Django needs to be imported:
Python pydiction.py Django django.conf django.contrib django.core django.db django.dispatch django.forms django.http Django.middleware django.shortuts django.template django.templatetags django.utils django.views
Finally: Markdown editor with good ah ~csdn I like you again