Questions tagged [vi]
a text editor that runs in a command line interface. Includes other variants such as vim
113
questions
0
votes
0
answers
25
views
Scrolling issue in vim after switch to iterm2
On my MacBook (Monterey 12.3.1), I recently switched from the standard terminal to iterm2. However, I noticed some strange behavior when using vim in the new terminal. If I scrolled to the top of ...
1
vote
1
answer
71
views
How to make Chinese pinyin keyboard work in vim?
When I am using a Chinese keyboard as input source, I cannot navigate around vim using regular keys.
I would like to leave the Chinese keyboard selected, but still be able to use vim as normal when I ...
0
votes
1
answer
304
views
How do I use homebrew to link MacVim and Vim at the same time?
I have used homebrew to install both Vim and MacVim on my mac. Right now, MacVim is the one that is linked. When I run mvim --version, I get the most recent and installed version that appears. When I ...
0
votes
1
answer
42
views
Repeat key when editing command lines in "set -o vi" mode
I have set the default shell to bash and have
set -o vi
alias vi=vim
set in the ~/.bash_profile. I also have With this configuration - and apparently some additional special sauce my prior laptop ...
0
votes
0
answers
606
views
How to map caps lock key to esc in visual studio code vim extension?
I see a lot of answers to this question that aren't related to mac, and still couldn't quite figure it out on my machine.
I previously worked on Ubuntu and migrated to a MacBook. I used the settings ...
0
votes
0
answers
133
views
Why can't I execute "bundle exec rake secret"? The error “bad interpreter: No such file or directory” occured
My ruby version is 2.7.3, my mysql version is 8.0.23, my mysql2 version is 0.5.3, my rails version is 5.0.7.2, and my Xcode version is 12.5.
I use macOS Big Sur(version 11.4) and the text editor &...
0
votes
1
answer
40
views
Vim — Automatically Doing a Linefeed When Editing a Markdown (.md) File
(MacVim 8.2, Terminal Vim 8.2, MacOS 10.14.6 Mojave)
Not sure when this started happening.
Whenever I edit a file with a .md extension, Vim immediately does a linefeed after I type certain lines, as ...
0
votes
0
answers
165
views
Why does setting Neovim as a man pager break GNU Info?
I know that this is sort of a 'Linuxy' question but it is Mac specific so I am putting it here. When I am working in the terminal on my mac (Catalina 10.15.7) I want to use Neovim rather than Less to ...
0
votes
1
answer
120
views
Map left command key to left control key in terminal only?
I'm using neovim to edit code and am needing to create a mapping in which I press the left command key, and neovim (or at least my alacritty terminal) thinks that I am pressing the left control key.
I ...
1
vote
0
answers
59
views
Vim in Iterm2 closes after compiling Latex file
When I run
!pdflatex %
in Macvim, the latex file compiles and I am not exited from Macvim. In iterm2, the compilation occurs and them I am taken out of Vim back into the terminal prompt. Any ideas ...
0
votes
0
answers
56
views
Colour no longer working in vim
I've been using vim for as long as I can remember. Never had a problem, until lately. For no reason that I can see, colour has stopped working. First noticed it when editing a Tex file, and I note ...
1
vote
1
answer
71
views
Quickly change the font size in Terminal
I'm looking for a way to perhaps type a command and have the font change by increments of say 5 or 10. Right now Cmd-+ is taking too long if I want to go from a small font to a large font. I'm using ...
3
votes
1
answer
193
views
MacVim color scheme has the right color, but vim through Terminal doesn't
I've installed color schemes that seem to be working well with MacVim.
When I run Vim using Terminal, however, the colors change and the color scheme doesn't appear to be working anymore.
Is there a ...
0
votes
1
answer
2k
views
I placed Neovim in usr/local/bin but getting permission denied
I'm not sure where to place the Neovim folder (after extracting it). Is the location usr/local/bin correct?
I get the following
zsh: permission denied: nvim
2
votes
1
answer
296
views
Vim frozen and unresponsive on startup
I am using zsh on macOS. When I type vim, it opens, but it is completely frozen:
Anything I press on the keyboard does not display or change the window. In order to exit, I have to terminate the ...
18
votes
1
answer
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
0
answers
45
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
1
answer
90
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
1
answer
94
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
1
answer
79
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
1
answer
156
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
1
answer
368
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
1
answer
1k
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 ...
2
votes
0
answers
76
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
1
answer
27
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 ...
8
votes
2
answers
17k
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
1
answer
283
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 ...
3
votes
1
answer
3k
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 /...
3
votes
0
answers
436
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
1
answer
756
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 ....
5
votes
4
answers
1k
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....
7
votes
4
answers
5k
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
1
answer
665
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
1
answer
868
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
1
answer
557
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
0
answers
79
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
1
answer
2k
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
1
answer
3k
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
2
answers
5k
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 ...
38
votes
5
answers
34k
views
How do I enable syntax highlighting in vim on Mac?
How do I enable syntax highlighting in vim on Mac?
4
votes
1
answer
2k
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
1
answer
457
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
1
answer
69
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
1
answer
363
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
1
answer
8k
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
1
answer
173
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
1
answer
698
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
2
answers
605
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
2
answers
856
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
1
answer
516
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> "=...