mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-01-03 23:04:36 +01:00
Enable omnicomplete for calibre code when editing calibre code in vim
This commit is contained in:
parent
d1eeaa5938
commit
39b323bff0
1 changed files with 6 additions and 1 deletions
|
|
@ -2,7 +2,7 @@
|
|||
let g:pyflakes_builtins = ["_", "dynamic_property", "__", "P", "I", "lopen", "icu_lower", "icu_upper", "icu_title", "ngettext"]
|
||||
|
||||
python << EOFPY
|
||||
import os
|
||||
import os, sys
|
||||
|
||||
import vipy
|
||||
|
||||
|
|
@ -11,6 +11,11 @@ project_dir = os.path.dirname(source_file)
|
|||
src_dir = os.path.abspath(os.path.join(project_dir, 'src'))
|
||||
base_dir = os.path.join(src_dir, 'calibre')
|
||||
|
||||
sys.path.insert(0, src_dir)
|
||||
sys.resources_location = os.path.join(project_dir, 'resources')
|
||||
sys.extensions_location = os.path.join(base_dir, 'plugins')
|
||||
sys.executables_location = os.environ.get('CALIBRE_EXECUTABLES_PATH', '/usr/bin')
|
||||
|
||||
vipy.session.initialize(project_name='calibre', src_dir=src_dir,
|
||||
project_dir=project_dir, base_dir=base_dir)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue