Closed vonum closed 4 years ago
Sounds like something is doing set syntax=fugitiveblame
before Vim has finished loading. Does that ring any bells?
You are rigth.
set filetype=fugitiveblame
- this line triggers the error.
However, it is after the part which loads plugins. This doesn't happen on ubuntu 18.04 where I also use the same dotfiles.
vimrc
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" let Vundle manage Vundle, required
Plugin 'gmarik/Vundle.vim'
Plugin 'vim-airline/vim-airline'
Plugin 'ervandew/supertab'
Plugin 'mileszs/ack.vim'
Plugin 'renderedtext/vim-bdd'
Plugin 'godlygeek/tabular'
Plugin 'plasticboy/vim-markdown'
Plugin 'tpope/vim-projectionist'
Plugin 'tpope/vim-rails'
Plugin 'tpope/vim-rake'
Plugin 'tpope/vim-cucumber'
Plugin 'tpope/vim-fugitive'
Plugin 'tpope/vim-surround'
Plugin 'tpope/vim-endwise'
Plugin 'tpope/vim-repeat'
Plugin 'tpope/vim-commentary'
Plugin 'thisivan/vim-bufexplorer'
Plugin 'gregsexton/MatchTag'
Plugin 'kien/ctrlp.vim'
Plugin 'elixir-lang/vim-elixir'
Plugin 'renderedtext/vim-elixir-alternative-files'
Plugin 'vonum/vim-python-alternative-files'
Plugin 'bogado/file-line'
Plugin 'pangloss/vim-javascript'
Plugin 'mxw/vim-jsx'
Plugin 'flazz/vim-colorschemes'
Plugin 'bkad/CamelCaseMotion'
Plugin 'drewtempelmeyer/palenight.vim'
Plugin 'szymonmaszke/vimpyter'
Plugin 'mattn/emmet-vim'
" All of your Plugins must be added before the following line
call vundle#end() " required
filetype plugin indent on " required
filetype plugin on
source ~/.vim/mappings.vim
source ~/.vim/config.vim
source ~/.vim/plugins_config.vim
plugins_config.vim
" Autocompletion settings
let g:SuperTabDefaultCompletionType = "<c-n>"
" markdown configuration
let g:vim_markdown_folding_disabled = 1
" CTRL P
let g:ctrlp_custom_ignore = '\v[\/]\.(git|hg|svn)|deps|_build|vendor$'
" Ack vim
let g:ackprg = "ack -H --nocolor --nogroup --column --ignore-dir={vendor,.git}"
" Search word under cursor
" nnoremap F :Ack "\b<cword>\b" app lib spec features config<CR>
" Disable AutoComplPop.
let g:acp_enableAtStartup = 0
" Enable JSX syntax highlight in .js files
let g:jsx_ext_required = 0
" Tree view depth
let g:netrw_liststyle = 3
" Fugitive colors
set filetype=fugitiveblame
" Python syntax highlighting
let g:semshi#mark_selected_nodes = 0
let g:semshi#simplify_markup = 1
let g:semshi#excluded_hl_groups = ['local', 'unresolved']
let g:python_highlight_string_templates = 1
let g:python_highlight_indent_errors = 1
let g:python_highlight_class_vars = 1
Do you have an idea on what could be the problem? Or if there were some similar issues?
Setting the filetype during Vim startup is a nonsense operation. Stop doing it. It was broken then and broken now, the only difference is that it's now breaking noisily instead of silently.
same issue Ubuntu 18
when using 9871822dd537c05ad805859cc217e9a40647e863
Error detected while processing function fugitive#BlameFileType[3]..<SNR>12_Dir:
line 1:
E117: Unknown function: FugitiveGitDir
-V2 log:
finished sourcing $HOME/.vimrc
could not source ".exrc"
Searching for "pack/*/start/*" in "/home/alex/.vim,/var/lib/vim/addons,/etc/vim,/usr/share/vim/vimfiles,/usr/share/vim/vim81,/usr/share/vim/vimfiles/after,/etc/vim/after,/var/lib/vim/addons/after,/home/alex/.vim/after"
not found in 'packpath': "pack/*/start/*"
Searching for "plugin/**/*.vim" in "/home/alex/.vim,/var/lib/vim/addons,/etc/vim,/usr/share/vim/vimfiles,/usr/share/vim/vim81,/usr/share/vim/vimfiles/after,/etc/vim/after,/var/lib/vim/addons/after,/home/alex/.vim/after"
sourcing "/home/alex/.vim/plugin/vim-dirdiff/plugin/dirdiff.vim"
finished sourcing /home/alex/.vim/plugin/vim-dirdiff/plugin/dirdiff.vim
sourcing "/home/alex/.vim/plugin/vim-fugitive/autoload/fugitive.vim"
finished sourcing /home/alex/.vim/plugin/vim-fugitive/autoload/fugitive.vim
sourcing "/home/alex/.vim/plugin/vim-fugitive/ftdetect/fugitive.vim"
finished sourcing /home/alex/.vim/plugin/vim-fugitive/ftdetect/fugitive.vim
sourcing "/home/alex/.vim/plugin/vim-fugitive/ftplugin/fugitiveblame.vim"
Searching for "autoload/fugitive.vim" in "/home/alex/.vim,/var/lib/vim/addons,/etc/vim,/usr/share/vim/vimfiles,/usr/share/vim/vim81,/usr/share/vim/vimfiles/after,/etc/vim/after,/var/lib/vim/addons/after,/home/alex/.vim/after"
not found in 'runtimepath': "autoload/fugitive.vim"
Error detected while processing function fugitive#BlameFileType[3]..<SNR>10_Dir:
line 1:
E117: Unknown function: FugitiveGitDir
finished sourcing /home/alex/.vim/plugin/vim-fugitive/ftplugin/fugitiveblame.vim
sourcing "/home/alex/.vim/plugin/vim-fugitive/plugin/fugitive.vim"
finished sourcing /home/alex/.vim/plugin/vim-fugitive/plugin/fugitive.vim
sourcing "/home/alex/.vim/plugin/vim-fugitive/syntax/fugitive.vim"
Searching for "syntax/diff.vim" in "/home/alex/.vim,/var/lib/vim/addons,/etc/vim,/usr/share/vim/vimfiles,/usr/share/vim/vim81,/usr/share/vim/vimfiles/after,/etc/vim/after,/var/lib/vim/addons/after,/home/alex/.vim/after"
line 8: sourcing "/usr/share/vim/vim81/syntax/diff.vim"
finished sourcing /usr/share/vim/vim81/syntax/diff.vim
continuing in /home/alex/.vim/plugin/vim-fugitive/syntax/fugitive.vim
finished sourcing /home/alex/.vim/plugin/vim-fugitive/syntax/fugitive.vim
sourcing "/home/alex/.vim/plugin/vim-fugitive/syntax/fugitiveblame.vim"
finished sourcing /home/alex/.vim/plugin/vim-fugitive/syntax/fugitiveblame.vim
alex@xray:~/.vim$ tree -L 3
.
├── colors
│ └── alex.vim
├── plugin
│ ├── vim-dirdiff
│ │ ├── doc
│ │ ├── plugin
│ │ ├── README.md
│ │ ├── screenshot.png
│ │ └── vim-dirdiff.git
│ └── vim-fugitive
│ ├── autoload
│ ├── CONTRIBUTING.markdown
│ ├── doc
│ ├── ftdetect
│ ├── ftplugin
│ ├── plugin
│ ├── README.markdown
│ └── syntax
└── syntax
└── mediawiki.vim
14 directories, 6 files
solution:
alex@xray:~/.vim$ tree -L 4
.
├── colors
│ └── alex.vim
├── pack
│ └── tpope
│ └── start
│ └── vim-fugitive
├── plugin
│ └── vim-dirdiff
│ ├── doc
│ │ └── dirdiff.txt
│ ├── plugin
│ │ └── dirdiff.vim
│ ├── README.md
│ ├── screenshot.png
│ └── vim-dirdiff.git
│ ├── branches
│ ├── config
│ ├── description
│ ├── HEAD
│ ├── hooks
│ ├── info
│ ├── objects
│ ├── packed-refs
│ └── refs
└── syntax
└── mediawiki.vim
16 directories, 10 files
It's installed wrong. None of that stuff should be in .vim/plugin
.
indeed - i moved it to pack. didn't know about this pack thing, not sure what's the difference with a plugin, I'll search. anyway, it seems to work now.
The error message is shown when starting vim on mac os
10.15.2
This is the list of plugins I have installed:
The functions like git blame, status, log, etc are working, but the message is shown every time i start mac vim.
vim --version
output: