Vim is an open-source text editor which is typically run from the command line. Questions should relate to using Vim on Ubuntu.

learn more… | top users | synonyms

1
vote
2answers
137 views

Ubuntu 16.04 VIM without python support!

Although Ubuntu 16.04 release notes mention that: The default VIM package has been built against python3 instead of python2. Yet after I installed vim with the following command: sudo apt-get ...
0
votes
0answers
12 views

YouCompleteMe plugin of VIM not working with NLTK

I have recently installed the YouCompleteMe plugin for vim through Vundle. It works really well for Python. Problem starts when I import the third party library nltk. For example if I do the following ...
1
vote
2answers
48 views

vim.desktop - changes lost when terminal exits

I was thrilled to notice a GNOME launcher for vim in the vim-common package after I upgraded to Ubuntu 16.04, since it offers an alternative to gvim (a solid app, though not perfect for my workflow). ...
0
votes
0answers
10 views

Are there any downsides/risks to using vim-gtk on production server?

I know this seems to be considered blasphemy but I really don't like editing server files with vi. If I install vim-gtk on my production server so I can use gvim and use x11 forwarding in putty to ...
3
votes
1answer
523 views

No python intepreter in vim for Ubuntu 16.04

I've recently installed Ubuntu 16.04 and in the Release Notes it says VIM defaults to python3 On my fresh install of Ubuntu 16.04 I installed vim with the following commands $ python3 -V Python ...
32
votes
5answers
15k views

How can I change the default text editor from gedit to vim?

How can I change the default text editor from gedit to vim? When I click on a text file, I want it to open in vim under the terminal instead of gedit.
1
vote
0answers
41 views

GLib-GObject-WARNING when closing gvim

I set my computer up new with Ubuntu 16.04 today. I already installed vim-gnome. While working with it, everything is fine. But when I close gvim I get this message in the terminal: (gvim:5834): ...
0
votes
1answer
48 views

badwolf color scheme does not work on ubuntu 14.04

I want to use color scheme badwolf for my vim so I downloaded it from here https://github.com/sjl/badwolf and copied colors/badwolf.vim to my ~/.vim/colors directory. But it does not work. It does not ...
8
votes
1answer
9k views

What's the easiest way to get Vim with Python 3 support?

I have Ubuntu 14.04 installed and Vim in its repos is compiled without Python 3 support. Because of that, python-mode plugin can't work with Python 3 code. What's the easiest way to get Vim with ...
5
votes
0answers
155 views

How can I change the cursor in vim depending if I'm in insert mode or normal mode?

I'm used to working on GVim, but I want to make most of vim+tmux too. Therefore I have decided to switch to vim. But in vim the cursor style does not change depending on the mode. I use zsh and ...
0
votes
3answers
55 views

Is it possible to have both vi and vim installed so that they can be used separately?

I can't use vi, well, I can, but I would much prefer vim, however I need to share a computer with someone who hates vim and can only use vi... After installing vim I find that if I use the vi command ...
14
votes
2answers
9k views

vi, getting multiple “Sorry, the command is not available in this version…” after reinstall

From my .vimrc, getting: line 16: E319: Sorry, the command is not available in this version: filetype on line 17: E319: Sorry, the command is not available in this version: filetype plugin on ...
1
vote
2answers
3k views

Vim refuses to start with “error while loading shared libraries: libperl.so.5.14” after upgrade to Ubuntu 14.04

After I upgraded to Ubuntu 14.04 vim refuses to start, showing the following error: vim: error while loading shared libraries: libperl.so.5.14: cannot open shared object file: No such file or ...
1
vote
0answers
23 views

Vim 7.4: Strange behavior with invalid actions

First of all: English isn't my mother language, please excuse any error on my post. Thanks! I have a problem with Vim 7.4 on my laptop installed Ubuntu 14.04. When I perform any invalid action ...
1
vote
1answer
34 views

Edit crontab with an editor other than the default

I would like to edit crontab with vi once. My default editor is nano, and I want to keep it that way. I only want to edit with vi one time. I don't want to change the default to vi then back to ...
1
vote
1answer
44 views

How to install Emmet (or any web development Plugins) for vim editor

I am trying to develop my Website but I am not interested on using graphical interfaces. I would like to use vim only. I went on this page http://www.vim.org/scripts/script.php?script_id=2981, but, I ...
1
vote
1answer
2k views

Vim YouCompleteMe installation

I'm trying to install YouCompleteMe plugin alongside my Vundle plugin manager for Vim. I've just added the Plugin 'Valloric/YouCompleteMe' line to my ~/.vimrc and then I wrote:PluginInstall in Vim, ...
1
vote
0answers
25 views

Setting vim background mode depeding on time of day

Several colorschemes in vim have two modes, which change the colors when you do set bg=light/dark. I'm wondering if it's possible to setup my .vimrc file such that it sets an appropriate mode ...
0
votes
2answers
143 views

Can't save .bashrc file in VIM (“The swap file ”.bashrc.swp“ already exists!”)

I have problem with .bashrc file I can't save changes by command :wq. When I put command to terminal vim .bashrc I have message like below. And when I choose "Edit" I am in .bashrc but :wq isn't save ...
2
votes
3answers
107 views

Problem selecting Vim version:

I use ubuntu 12.04. I want to install the latest version of Vim(7.3) with all its important plugins. So, which version of Vim should I install?: Vim or Vim-Gnome or Vim-athena or any other version? ...
0
votes
0answers
20 views

Open file in vim using symbolic link

I have symbolic link in current directory that points to text file. How to open file in vim using that symbolic link? command vim linkname not works.
24
votes
3answers
14k views

How to stop Gedit, Gvim, Vim, Nano from adding End-of-File newline char?

Sometimes I want the last line of a text file to be a simple string of text with no newline character appended: ...eg. to concatenate another file to it. Several editors automatically modify my ...
0
votes
1answer
46 views

vim theme showing up strange in tmux

My vim is configured like so: syntax on colorscheme brogrammer set nu set expandtab set tabstop=4 set autoindent My tmux is configured like so: set -g default-terminal "xterm-256color" ...
0
votes
0answers
72 views

unable to install vim on docker's ubuntu container

Using ubuntu 14.04 platform, installed docker: ubuntu@ubuntu:~$ docker --version Docker version 1.10.2, build c3959b1 in docker, running ubuntu image/container root@2a14c4a7b565:/# uname -a ...
106
votes
4answers
86k views

How can I install and use powerline plugin?

Powerline is a plug-in to display informational and beautiful statusline for vim, tmux and shell prompt for bash, zsh. Vim statusline: How can I install and setup Powerline for different ...
3
votes
1answer
42 views

When writing a Bash script, how do I create then open a file with the date as part of the name?

I want to use a script to open a list of URLs, then create an empty text-file called "[today's date].homework" and then open that text file in Vim. Here's the script I have now: #!/bin/bash ## Open ...
-3
votes
1answer
96 views

How can I view a text file with Chinese characters in Vim?

I have a text file with Chinese characters. I can view it in gedit and it works fine, but when I try to open it with Vim I see things like: »¹Ã»ºÃºÃ¸ßËÑÑ©»¨ÕÀ·ÅµÄÆøºò£¬ÄôÀÚ¹âÈáÈõºì´øÉÏÀ­²»Éϵľ糡°æ, ...
48
votes
1answer
62k views

What are the differences between the different vim packages available in Ubuntu?

The difference between vim-gtk and vim-gnome has been discussed here. Ubuntu usually offers more than these two options for vim : vim-nox vim-athena vim-* It is not clear which vim package ...
0
votes
0answers
31 views

Make vim version 7 edit xml files

I'm using old linux an vim version 7.1.314. I would like to edit eclipse .cproject file that build using XML syntax. Currently vim shows not colored information. I found vim plugin that I hope wil ...
-2
votes
1answer
39 views

How do i use a color scheme on vim and gvim?

Both are installed on: ~/.vim/colors And are found on the command line: Link do Colorscheme - solarized Link do Colorscheme - sky
0
votes
0answers
27 views

Blank Screen On Boot

I tried installing LAMP using the following tutorial: http://techlimbo.blogspot.com/2012/11/how-to-install-concrete5-on-ubuntu-1204.html Upon testing if the apache install worked (directing browser ...
0
votes
0answers
53 views

How can I find the directory to clang-format

I use gvim to code and want to use clang-format as a plugin. As I read it is already integrated in vim. I just need to add this line to my .vimrc: map <C-K> :pyf ...
0
votes
0answers
78 views

Can't copy from vim to clipboard inside tmux

I am using vim vim 7.4, tmux 2.1 and ubuntu 14.04. I can yank from vim and copy to clipboard when using vim directly from my terminal with "+y. When I use vim from inside tmux, I can't yank-copy from ...
0
votes
0answers
29 views

Vim copy to clipboard not working

Trying to copy text from vim to clipboard and paste to another application. Vim should support copying to clipboard (:echo has('clipboard') returns 1) I do: in visual mode select required lines type ...
1
vote
1answer
54 views

How to redraw terminal window after wall command displays message

I have a script that will send wall notification to all open terminal sessions when battery gets bellow certain percentage,and will continue doing so every minute until power source is plugged in. ...
3
votes
5answers
797 views

Difference between Nano and Vim [closed]

I have recently started using Ubuntu and hence, the terminal. As text editor, I have used the pre-installed nano. Now I wonder whether I should install and use vim as well. What are each of those ...
0
votes
0answers
17 views

Why does ^[k appear in vim?

Occasionally my fingers will twitch in vim and these characters appear: ^[k (I'm not typing the characters, and they're not part of the text - deleting the line doesn't remove them) What are they ...
0
votes
0answers
78 views

SSH secure shell not working with vim colors

The script: 256colors2.pl when run from putty returns the correct colors, from SSH secure shell nothing happen, it doesn't open, on-screen appears nothing. user@ubuntu:~$ ./256colors2.pl ...
7
votes
2answers
39k views

Vim installation in Ubuntu 14.04

I am unable to install Vim and need help. I've tried the following: root@cbitlab1:/home/cbitlib1# sudo -s root@cbitlab1:/home/cbitlib1# apt-get install vim Reading package lists… Done Building ...
1
vote
1answer
59 views

Open all files in directory in vim

To open several files in separate tabs in vim I need to execute command vim -p file1 file2 I fave directory that contains many files and I would like to open all files with extension c in vim ...
0
votes
1answer
24 views

Text scaling / clipboard issue

I am having some difficulty understanding some issues with dia, perhaps better posted as two questions, however I do get the impression that they are related in gnome somehow; they are as follows: ...
1
vote
0answers
128 views

Bash shell doesn't display Python output

I started using vim + tmux for my programming and suddenly after accidentally smashing couple of keys [Forgive me I am a klutz] the bash shell started acting weirdly. When I run my unittest written ...
6
votes
3answers
21k views

Changing Vim editor settings?

How do I change default settings of Vim editor such as setting auto indent, setting Tab space to 4 and changing text colors? Also how to set vim as the default code editor?
28
votes
5answers
17k views

vim is not remembering last position

My Ubuntu LTS 12.04 has vim editor. If I open a file, move to a paragraph and reopen vim, then the cursor goes to beginning of the file always. This is not the expected behavior. How the vim can ...
1
vote
2answers
583 views

Browse files with vim in terminal

Is there any way to open file with vim in the terminal without typing file name, but for example then I see in the directory my file, go with arrow keys or something like that? I think I saw one of ...
4
votes
1answer
5k views

Can I open two or more files in vim at once?

I have a file with the name First.txt, which I opened that by vim. Now I want to go another file which its name is Second.txt . How to open Second.txt while I do not close First.txt. How to switch ...
1
vote
1answer
406 views

I want to install vim with ruby support on Ubuntu 15.04 vivid vervet

I have installed Ubuntu 15.04 and am trying to set up my Ruby on Rails environment to program. I use vim as the IDE and it comes pre-installed without ruby support: vim --version | grep -i ruby ...
6
votes
3answers
6k views

Replacing vi by vim

In my college our Admin has replaced vi by vim. So how do I replace vi by vim so that, when I type vi in terminal, then vim should get opened. I know doing so is silly, but I am asking it just out ...
0
votes
2answers
57 views

What does % and ! mean in Vim commands?

In Vim, :%!ls executes ls command and prints its output to the current editable file. But what do % and ! mean separately in vim? Is it possible execute ls and not put its output to document?
4
votes
2answers
1k views

running python in vim

I have tried Googling but I couldn't find anything relevant. Is it possible to program in Python on VIM and do something like :!iPython to have Python execute the code? Last time I tried that, ...