I Fixed My Autocomplete

< 2 minute read.

I have been us­ing vim for over two years now. Orig­i­nal­ly start­ed with vrap­per, which helped a lot: when I need­ed my orig­i­nal pro­duc­tiv­i­ty, I was able to go back by switch­ing off vim-mode in Eclipse. Lat­er used vim mode in QtCre­ator un­til fi­nal­ly ful­ly mak­ing the switch, ev­ery now and then work­ing in Vis­ual Stu­dio with some vim plug­in.

Gen­er­al­ly it im­proved my ef­fi­cien­cy as I feel less held up with the ex­ce­cu­tion side of cod­ing: when I know what to do, I can turn that in­to code rather quick­ly… as long I’m not us­ing a mac-key­board.

What al­ways both­ered me, though, was my lack of prop­er au­to­com­ple­tion. Not be­cause that isn’t pos­si­ble in vim—I had the YouCom­pleteMe plug­in in­stalled for­ev­er—, rather the lack of ac­tu­al­ly set­ting it up prop­er­ly. In­stead it con­sis­ten­ly greet­ed me with an er­ror about python when­ev­er I opened vim, mak­ing me click “ok” on a di­a­log first.

I am still baf­fled by how long I man­aged to pro­cras­ti­nate this is­sue that kept the en­tire plug­in from work­ing. I al­ways saw it as a nui­sance to have to deal with my ed­i­tor in­stead of cod­ing (fun­ny I chose the most con­fig­u­ra­tion de­mand­ing ed­i­tor in de­spite of this). To­day was the day, though. I fixed it by in­stalling Python 2.7.15 on my Win­dows ma­chine along­side the Python 3.6 I al­ready had.

Now I can even prop­er­ly com­plete Ul­tiSnips snip­pets. That was al­ways some­thing I ad­mired when watch­ing high­ly ef­fi­cient vim users.

Writ­ten in 20 min­utes.