on PC, I set an environment variable HOME=C:\Users\warwargr I then create a .vimrc file in my %HOME% directory, and in this file I put set viminfo= let testvar="Thanks" " :filetype off " Make double- clear search highlights nnoremap :nohlsearch (The " in .vimrc represents a comment) (Uncomment the filetype line for type dependent editing) you can then see this is working with the commands :echo testvar :scriptnames -------------------------- On PC :dig show digraphs need to do :set fileencoding=latin1 :set encoding=latin1 Rg --> � --> Unicode 174 * This gets three chars under the cursor and let x = strpart(getline("."), col(".") - 1, 3) echo x http://vimdoc.sourceforge.net/htmldoc/eval.html#functions * **************************************************** * I found out that file completion was not working I had to run complete -p vim complete -r vim Now it works file * **************************************************** To disable logging echo "set viminfo=" >! .vimrc This is equivalent to typing the command :set viminfo= in the editor itself * use Shift-V to turn visual block on and off use "d" to delete a visual block * Links https://www.cs.swarthmore.edu/help/vim/searching.html For using mac.exe macros with unicode chars we do not want the file to be utf-8 encoded, because mac.exe does not use that, so we want it to be latin1 :set fileencoding=latin1 Thus the full recommended .vimrc file is : set viminfo= set encoding=utf-8 set fileencoding=latin1 This will ensure that any file will be written in single bytes. If a file is messed up, you may need to open it with vim, and then :set fileencoding=latin1 and then write the file back out.