Questions tagged [vi]

a text editor that runs in a command line interface. Includes other variants such as vim

Filter by
Sorted by
Tagged with
18
votes
1answer
2k views

How could macOS be POSIX compliant without vi?

As macOS is POSIX compliant and Unix certified, why does vi redirects to vim? As I understand, vim is not POSIX compliant. So how did Apple obtained a Unix certification without having vi installed on ...
1
vote
0answers
17 views

Copy/Cut and Paste from VIM inside Terminal

I am able to copy/cut and paste from the terminal using the mac clipboard. However, when I am inside VIM, over SSH, this feature doesn't seem to work. The options are greyed out. Copy Special is ...
0
votes
1answer
29 views

How to fix menus and windows in macOS 10.14.6 that do not show any items?

I am using a 13-inch MacBook Pro with macOS 10.14.6 (Mojave) installed. I am trying to utilize the Terminal, however, I cannot see any information in the terminal window. For example if I type vim and ...
0
votes
1answer
22 views

how to set afplay as default media player for wma files in mac OS

Hi I am using a vim plugin named eblook which turns vim console into a dictionary. The problem is that the implementation of the plugin is using a default player for WMA file to play the sound file (...
0
votes
1answer
61 views

Unicode escape is ctrl+[ , why does this work in terminal or vim, but not safari or other parts of OS?

When i'm working in VIM i'll often times use ctrl+[ to exit insert mode. But if i need to press escape in other parts of the OS ctrl+[ does not act the same way as escape. For example if search a ...
0
votes
1answer
47 views

vim ignoring .vimrc syntax highlighting

I had a ~/.vimrc with some basic syntax highlighting that was working fine until I upgraded to Catalina. Running vim -V I see it loads my vimrc but it totally ignores anything in it. If I run :so ~/....
1
vote
1answer
251 views

What was the first version of macOS to ship with the Vim text editor?

Since macOS (originally Mac OS X) is a variant of UNIX, and has been POSIX-certified for a while, I assume it’s always had the vi text editor available. In recent versions, it has come with Vim. Has ...
2
votes
1answer
296 views

How to improve into vim of MacOS Mojave the speed of vertical scroll with bottom/up keys?

I transfer the original post from StackOverflow (Original post) to here since this is about Apple specificity. I have a new macbook with Mojave and vim already installed. Unfortunately, even for ...
1
vote
0answers
31 views

Vim-like clipboard manager with multiple buffers

I am looking to expand the capabilities of my clipboard. I've grown attached to how vim does it; multiple discrete buffers you can 'yank' (copy) text into. I also generally prefer to use the mouse ...
0
votes
1answer
26 views

Pass keyboard input to cli after exiting vim

Some irritating thing when doing git commit - what I'd like to type (really fast :)) git commit -a --amend :wq<CR> git push -f My problem is that after :wq<CR> I have to wait until vim ...
2
votes
2answers
6k views

Make Homebrew installed Vim override system installed one

I have troubling merging several version of vim on my machine. I have successfully installed vim via Homebrew. Here's the output of running brew info vim: vim: stable 8.1.1550 (bottled), HEAD Vi '...
0
votes
1answer
77 views

Safari extension for Google results navigation (↑/k, ↓/j)

Title says it all. I found some posts linking to some private locations (mostly dead). I wonder if there ain't something like that for Safari. Google Chrome has several of them. E.g. Web Search ...
0
votes
1answer
908 views

How can I edit the default vimrc file? (it's read only, and chown and chmod says 'operation not permitted')

How can I edit the default vimrc file on osx? (sudo chown ... gives Operation not permitted ) In osx vim /usr/share/vim/vimrc is the default vimrc file My username is 'apple' If I try to do vim /...
2
votes
0answers
217 views

Can't scroll using the touch screen on iOS devices within vim

Over the past days I've started to do my day-to-day (development) work on my iPad instead of the MacBook. I have the MacBook Pro always online and available to connect to over ssh but have a problem ...
0
votes
1answer
474 views

unable to setup powerline for vim

I'm new to mac and would like to setup powerline program for terminal and vim. I was able to setup to the bash shell but cannot do it for vim. I can setup for terminal. This is what I've added to ....
2
votes
2answers
630 views

Vim like navigation keys for Finder

So I use vim all the time, and I've grown use to the navigation keys h, j, k, l, (especially when navigating with NERDTree). Does anyone know if it's possible to implement this motion in macOS Finder....
4
votes
2answers
3k views

Homebrew Vim with Python support depends on Python 3.7.0, and I have to use 3.6.5

I have to use Python 3.6.5 because of a library I use that keeps showing bugs on 3.7.0 (TensorFlow). I installed Python 3.6.5 using Homebrew as follows: brew install https://raw.githubusercontent....
3
votes
1answer
377 views

How do you insert literal control chars in vim on Mac?

How do you insert literal control characters in vi on Mac? For example what is the Mac equivalent of Unix ^V^M Windows ^Q^M (in vim) to insert a \r into a substitution string?
0
votes
1answer
620 views

E319: Sorry, the command is not available in this version on macvim

While trying to prepare macvim environment to work with clang-format I did: $ vim ~/.vimrc map <C-K> :pyf /usr/local/Cellar/clang-format/2018-04-24/share/clang/clang-format.py<cr> imap &...
0
votes
1answer
291 views

Can we capture a screenshot of vim window using Terminal?

Let's say I have a file called hello.py. # File: ~/hello.py print('Hello') print('Stack Exchange') I would like to get a screencapture of hello.py when opened in vim editor as the ~/hello.png. Need ...
1
vote
0answers
74 views

Can't see how to run vi having installed it (I want Vi to run Vi not Vim)

I am trying to run Vi (not Vim), because i'm curious about some older commands like :open. I saw this https://www.reddit.com/r/vim/comments/1u0q0b/how_to_install_traditional_vi_not_vim_on_os_x/ it ...
2
votes
1answer
822 views

Cannot type right curly brace in VIM

For some reason, I cannot type right curly braces (}) in VIM. On my German keyboard, the shortcuts are <ALT-8> and <ALT-9> for left and right braces, respectively. These work in all ...
2
votes
1answer
1k views

How to clear selection in OS X Terminal?

Usually in Terminal to delete text you have to sit there for an hour holding the ⌫ Delete. This is particularly annoying since I use vim in the terminal for Text file editing. But anywhere else in ...
1
vote
2answers
4k views

Installation of mac brew vim version 8.1

I'm using brew vim which is currently at version 8.0.1850 but 8.1 has just been released and I'm wondering if there is a way to upgrade to it yet? I've done some digging and can't see an option to do ...
23
votes
3answers
16k views

How do I enable syntax highlighting in vim on Mac?

How do I enable syntax highlighting in vim on Mac?
2
votes
1answer
1k views

Is it possible to edit a macOS alias with vim?

I like to use macOS's alias feature to not have to make redundant files. These aliases work great with Chrome and TextEdit. When I open them with vim, however, I get a giant messy file (presumably the ...
0
votes
1answer
368 views

How to install vim8 without effecting the built-in vim?

How can install vim8 without effecting the built-in vim that comes with a mac? Like with python2 that comes built-in with a mac, I have python3 separate. So, I can call it with vim8. I am using brew. ...
1
vote
1answer
55 views

Remove 'CMD+i' shortcut from Terminal

I am hoping to use CMD+i to replace esc in vim but found that CMD+i is mapped to Show Inspector. How do I remove this so that I can free up this shortcut in vim?
1
vote
1answer
310 views

Mouse scroll and trackpad behaving differently

I am using a dell mouse with my mac. Although in most context scrolling the mouse wheel produces the same effect as swiping down with two fingers, it sometimes happen that the mouse does not work. One ...
2
votes
1answer
5k views

‘Swap file “./.bash_profile.swp” already exists’

I'm trying to edit .bash_profile because I am installing the JDK on my Mac. When trying to open up the file using vi ./.bash_profile, it shows an error because there was a swp file of bash. It also ...
0
votes
1answer
124 views

Found a socket called “chaos_control” in my home directory, what is it?

I did an ls in my home directory and along with my normal folders it listed a file called chaos_control. It does not show up in Finder even when I show hidden files. I ran file chaos_control and it ...
2
votes
1answer
566 views

Available colors in iTerm / terminal.app

I'm trying to make my own colorscheme in Vim, but are struggling to see the available colors in iTerm. Here are my iTerm-color-settings: Here's how I can use it in Vim (for example using ctermfg=...
1
vote
2answers
342 views

Open a MacVim (gvim) window from MacVim

On Ubuntu/Windows when I have a gvim window open I just type :!gvim filename to open a new window. On OSX this does nothing. I think it may have to do with OSX not liking multiple instances of the ...
4
votes
2answers
766 views

Copying text in vim to the global clipboard

On my linux computer I am able to copy text to the clipboard with the command "+y. How do I do the same on Mac?
2
votes
1answer
448 views

Vim mappings not working in OS X

I have the following lines in my .vimrc for Ubuntu. They insert the current date as a string, and insert my signature at the bottom of the currently open file, respectively: :map <F2> "=...
0
votes
1answer
185 views

How to automatically disable trackpad when I am coding with vim in iTerm2?

As the touchpad is bigger now, when I am coding in vim, my thumbs occasionally touch the trackpad and thus move the cursor to somewhere else, which is extremely annoying. How to disable trackpad ...
4
votes
1answer
56 views

Why is [dos] sometimes in the output of a save in “vim”. such as: “foo.txt [dos] 38L, 193C”?

In certain text files, after doing a save in vim with :w, the output mentions [dos] as such: "foo.txt" [dos] 38L, 193C Why is [dos] displayed? As a simple test, I've created a new file with vim on a ...
4
votes
2answers
2k views

Vim the editor keeps crashing on Sierra

I love using Vim through Terminal.app. Everything was fine until three days ago, when Vim starts to crashing. Each crash happens when I enter a newline('\n') character in the Edit Mode, but not every ...
1
vote
1answer
118 views

Why do I have to use sudo although I'm already a member of wheel?

I like to edit files in my /Library/WebServer/Documents without having to run sudo all the time. So I simply added my username abbood to the wheel group using this command: sudo dseditgroup -o edit -...
2
votes
0answers
1k views

`CFPasteboardRef CFPasteboardCreate(CFAllocatorRef, CFStringRef) - failed to create global data` warning in vim

I just installed vim using brew $ brew install vim I am on a ssh connection to a MacOSX desktop. I am heavily using homebrew. As soon as try to delete a character or copy something in vim, I get ...
10
votes
1answer
4k views

How to show italic in vim in iTerm2

The beloved Solarized colour scheme seems to apply an italic face for comments, but when I am using it in vim in iTerm2, it does not. So, everything including comments are displayed in Roman (normal) ...
1
vote
1answer
81 views

Not able to write a file with root

I am trying to write to a vim file, fortran.vim. I gave myself access to root following these guidelines. I also saw this SO post, but the answers did not help. sh-3.2# ls -l fortran.vim -rw-r--r-- ...
1
vote
1answer
2k views

iTerm2 applies strange color to vim's default

When I updated my iTerm2 recently in November (the main release, not nightly-build), colors are rendered strange. Fortunately, I restored old iTerm2 in the trash can, and made a comparison. In each ...
1
vote
1answer
228 views

Macvim can not load custom Powerline fonts when started from tmux session

I have a really strange issue with MacVim + Tmux + Powerline Fonts. I can run MacVim from the dock or terminal and it correctly starts with Powerline fonts. When I start a tmux session, and launch ...
4
votes
1answer
2k views

RBENV managed Rubies: VIM upgrade forcing homebrew to install Ruby

I've recently switched from RVM to RBENV as my Ruby manager under MacOS Sierra. $ rbenv version 2.3.1 (set by /Users/meltemi/.rbenv/version) $ which ruby /Users/meltemi/.rbenv/shims/ruby I've used ...
13
votes
2answers
27k views

How to upgrade system default vim?

Finally, vim 8.0 has been released! However, the pre-installed vim is vim 7.3 on my system(OS X El Capitan), and I want to upgrade it to the newest 8.0 version. So how can I do this without messing ...
0
votes
1answer
475 views

nginx.vim syntax highlighting

Attempting to use a VIM syntax highlighting plugin for editing nginx config files on El Capitan. It doesn't take. It asks that you place these files and add these directores: ~/.vim/syntax/nginx.vim ...
2
votes
3answers
1k views

Can you work with Vim on iPad Mini with an external keyboard?

I'm considering to buy an iPad Mini and use it -- among other things -- for programming using Vim. I would connect via SSH to a Digital Ocean server and start Vim there. I would use an external (...
4
votes
1answer
16k views

Where is the folder with color schemes used by vim?

I use vi on mac os x at work and on Ubuntu at home. I like the colorscheme vim uses on the mac and I'd like to copy the corresponding file on ubuntu, but I can't find it, since there's no ~/.vim ...
0
votes
2answers
1k views

Copying and pasting between tmux panes containing vim instances over SSH in Terminal.app

I use vim to develop Perl code on a remote Linux box running Debian Jesse. The machine is a virtual machine running in VirtualBox. I use ssh and then issue a vim <file> command to start editing ...