" VIM Configuration
set nocompatible
" Activate pathogen
execute pathogen#infect()
filetype plugin on
filetype detect
" How can I make the toolbar stay hidden after a restart?
set guioptions-=T
" How can I prevent Finder file labels from disappearing when saving a file?
set backupcopy=yes
" -- Display
set title " Update the title of your window or your terminal
set number " Display line numbers
set ruler " Display cursor position
set wrap " Wrap lines when they are too long
set scrolloff=3 " Display at least 3 lines around you cursor
" -- Search
set ignorecase " Ignore case when searching
set smartcase " If there is an uppercase in your search term
" search case sensitive again
set incsearch " Highlight search results when typing
set hlsearch " Highlight search results
" -- Beep
set visualbell " Prevent Vim from beeping
set noerrorbells " Prevent Vim from beeping
" Backspace behaves as expected
set backspace=indent,eol,start
" Hide buffer (file) instead of abandoning when switching
" to another buffer
set hidden
" Enable syntax highlighting
" syntax enable
" Enable file specific behavior like syntax highlighting and indentation
" filetype on
" filetype indent on
" Use the dark version of Solarized
set background=dark
colorscheme solarized
set guifont=Monaco:h14
set antialias
let g:prettier#autoformat = 0
let g:prettier#exec_cmd_path = "/Users/currentuser/.vim/bundle/vim-prettier/node_modules/prettier/bin-prettier.js"
FYI: I've tried it with and without the custom vim-prettier configuration in my .vimrc and still get the errors.
vim --version
vim --version
VIM - Vi IMproved 8.1 (2018 May 18, compiled Oct 30 2019 11:57:56)
macOS version
Included patches: 1-2234
Compiled by travis@Traviss-Mac.local
Huge version with MacVim GUI. Features included (+) or not (-):
+acl +file_in_path +mouse_urxvt -tcl
+arabic +find_in_path +mouse_xterm +termguicolors
+autocmd +float +multi_byte +terminal
+autochdir +folding +multi_lang +terminfo
-autoservername -footer -mzscheme +termresponse
+balloon_eval +fork() +netbeans_intg +textobjects
+balloon_eval_term +fullscreen +num64 +textprop
+browse -gettext +odbeditor +timers
++builtin_terms -hangul_input +packages +title
+byte_offset +iconv +path_extra +toolbar
+channel +insert_expand +perl/dyn +transparency
+cindent +job +persistent_undo +user_commands
+clientserver +jumplist +postscript +vartabs
+clipboard +keymap +printer +vertsplit
+cmdline_compl +lambda +profile +virtualedit
+cmdline_hist +langmap +python/dyn +visual
+cmdline_info +libcall +python3/dyn +visualextra
+comments +linebreak +quickfix +viminfo
+conceal +lispindent +reltime +vreplace
+cryptv +listcmds +rightleft +wildignore
+cscope +localmap +ruby/dyn +wildmenu
+cursorbind +lua/dyn +scrollbind +windows
+cursorshape +menu +signs +writebackup
+dialog_con_gui +mksession +smartindent -X11
+diff +modify_fname -sound -xfontset
+digraphs +mouse +spell +xim
+dnd +mouseshape +startuptime -xpm
-ebcdic +mouse_dec +statusline -xsmp
+emacs_tags -mouse_gpm -sun_workshop -xterm_clipboard
+eval -mouse_jsbterm +syntax -xterm_save
+ex_extra +mouse_netterm +tag_binary
+extra_search +mouse_sgr -tag_old_static
-farsi -mouse_sysmouse -tag_any_white
system vimrc file: "$VIM/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
user exrc file: "$HOME/.exrc"
system gvimrc file: "$VIM/gvimrc"
user gvimrc file: "$HOME/.gvimrc"
2nd user gvimrc file: "~/.vim/gvimrc"
defaults file: "$VIMRUNTIME/defaults.vim"
system menu file: "$VIMRUNTIME/menu.vim"
fall-back for $VIM: "/Applications/MacVim.app/Contents/Resources/vim"
Compilation: clang -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_MACVIM -Wall -Wno-unknown-pragmas -pipe -DMACOS_X -DMACOS_X_DARWIN -g -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: clang -L. -fstack-protector-strong -L/usr/local/lib -L/usr/local/opt/libyaml/lib -L/usr/local/opt/openssl@1.1/lib -L/usr/local/opt/readline/lib -L. -fstack-protector-strong -L/usr/local/lib -L/usr/local/opt/libyaml/lib -L/usr/local/opt/openssl@1.1/lib -L/usr/local/opt/readline/lib -L/usr/local/lib -o Vim -framework Cocoa -framework Carbon -lm -lncurses -liconv -framework AppKit -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE
Related issue:
E121: Undefined variable: g:prettier#autoformat when executing vi #161
Do you want to request a feature or report a bug? Bug
What is the current/expected behavior? No Errors when opening a file
What version of
vim-prettier
are you using - (output of:PrettierVersion
) ?0.2.7
What version of
prettier
are you using - (output of:PrettierCliVersion
) ?1.18.2
What is your
prettier
executable path - (output of:PrettierCliPath
) ?/Users/currentuser/.vim/bundle/vim-prettier/node_modules/prettier/bin-prettier.js
Did this work in previous versions of vim-prettier and/or prettier ?
I didn't remember this error in previous version, but have been ignoring the errors for so long I could be mistaken.
Additional details
macOS Mojave:
10.14.6
node -v:
v13.0.1
pathogen -v:
2.4
/Users/currentuser/.vim
.vimrc
FYI: I've tried it with and without the custom
vim-prettier
configuration in my.vimrc
and still get the errors.vim --version
Related issue:
E121: Undefined variable: g:prettier#autoformat
when executingvi
#161cc: @hankchiutw