Questions tagged [linux]
For questions specific to the Linux operating system.
138
questions
0
votes
1
answer
41
views
How to correctly set up :make for building Vim?
My question could fairly be a duplicate of this, but I hope I'm making it critically different by asking about :makeing Vim itself and having a meaningful quickfix window. (In reality, my use case is ...
-1
votes
0
answers
45
views
vi / Vim statusline current line number is gone
I have tried all of the suggestions to restore a statusline which displays the current line number and column as VI did by DEFAULT. e.g, fc12, fc17, fc21,
But with Fedora Core 34 someone apparently ...
0
votes
0
answers
30
views
Vim displays help at seemingly random moments
I face an issue: When I edit a file in Vim, and while editing/scrolling or even just having the file open, the help screen pops up, and I have to leave the help before I can do something again.
It ...
1
vote
1
answer
61
views
Build a custom vim binary with python syntax highlighting
Background
The Debian 11 vim package doesn't include python3 support. See the section titled "No python support in Debian 11 vim - evidence" below
I need vim with python3 support for the ...
0
votes
0
answers
25
views
How to add custom text to vi airline?
How can I add custom text to vim airline?
For example the word evgenimba in the right botton of the picture below?
I have tried to search with various keyword but could not find the solution.
1
vote
1
answer
50
views
Replace arithmetic expression by their result
I am just trying to replace several arithmetic expressions inside a script file, which I cannot seem to find a simple solution for on the web.
Adapting this answer did not do the trick.
Suppose I have ...
0
votes
0
answers
21
views
Building from source ,perl ruby lua and python support are not activating, why?
Here are the things I have :
The configure snippet I am using :
./configure --with-features=huge --enable-rubyinterp=yes --with-ruby-command=/usr/bin/ruby ---enable-pythoninterp=yes --with-python-...
0
votes
0
answers
29
views
gvim menus are too big
Many compiler, install module, gyrations later, I was finally able to get vim with the gui to compile and execute.
However, the menus, both at the top of the main screen, and the pull down menus are ...
0
votes
1
answer
22
views
Vim modeline settings options words appear in selected in red
The vim modeline settings options words appear in selected in red in the first line :
# vim: set ft=json noet:
I'm using vim 7.4 on CentOS Linux 7.9.
How can I disable that ?
1
vote
1
answer
129
views
vim broken after python update (error while loading shared libraries: libpython3.9.so.1.0)
I built vim from source with option --enable-python3interp.
But after a system wide update (pop-os / ubuntu 21 to 22.04), python went from 3.9 to 3.10 and I suppose this is what broke my vim:
$vim
vim:...
1
vote
1
answer
27
views
Turning on vi in terminal after returning to terminal [closed]
So I have set -o vi set in my .bashrc file
When I open terminal it starts in INSERT mode.
How can I make it so that it starts in NORMAL mode?
0
votes
1
answer
611
views
super key not working in neovim on linux
I'm trying to create a shortcut, but I can't get vim to recognize my super key. I tried the following combinations:
lvim.keys.normal_mode["<A-h>"] = ":BufferLineCyclePrev<cr>...
0
votes
0
answers
109
views
How to adjust text color for Texinfo
I am working with Vim 7.4 on Linux (Xubuntu 14.04). I am editing Texinfo files and I would like to adjust the color of ordinary text. The colors of other items (@ macros, comments, etc.) are all okay. ...
4
votes
1
answer
639
views
How can I print from nvim on linux
I would like to be able to send my currently open text file to the paper printer.
I often use nvim to create a daily scratch to do list, and need a paper copy to go with me in my back pocket through ...
1
vote
1
answer
469
views
Tab page is closing when deleting buffer
I'm using bufferline.nvim in order to display both buffers and tab pages on the tabline, whenever i delete a buffer with bd, all the buffers on that tab page are deleted as well, alongisde with the ...
2
votes
1
answer
525
views
Remapping Ctrl+backspace in insert mode to delete one word back
I want to bind Control+Backspace in insert mode to delete a word. I'm able to bind Control+Del in both insert and normal modes, but I can only seem to bind Control+Del in normal mode.
I've checked ...
0
votes
0
answers
60
views
High vim CPU usage at GUI but not the CLI
I've previously noticed that vim spikes up the CPU usage whenever I scroll up or down at the terminal emulator within the GUI , and when I inspect the process it turns up to be xorg .
I tried to ...
0
votes
0
answers
54
views
vim in xterm not redrawing properly
Since this problem exists only when using vim in an xterm (neither gvim nor vim in aterm demonstrate this on my computer) this is likely not a vim problem, but because it is sooooo annoying when using ...
0
votes
0
answers
60
views
Vim open/close slowly in remote computer due to sourcing a file
Vim works (open/close) slow in remote computer. Other tasks such as giving basic commands like ls works faster. Compilation is also slow. In the output of vim --startuptime, there is a jump in time ...
18
votes
2
answers
4k
views
Vim cannot find medical spell files
Problem specification
I would love to have a medical spell dictionary in vim.
Currently, I have a lot of medical terms in my own personal English dictionary right now. However, using an official ...
0
votes
1
answer
989
views
vim ctrl+c doesn't copy/paste with ctrl+c or ctrl+v
I was trying to map ctrl+c to copy, ctrl+v to paste in vim, but it's not working properly.I've tried https://stackoverflow.com/questions/61177658/mapping-select-all-copy-paste-in-vim and https://...
2
votes
1
answer
565
views
Mapping <Shift>-Insert to paste in gVim search field
In gVim (not terminal Vim), I want to be able to paste from <Shift>-Insert (a.k.a. C-V) into the text input field of a search. I.e. when I press "/", and go into search mode, I want ...
0
votes
1
answer
41
views
How do I get the line numbers to permanently appear in vim [duplicate]
I keep wanting to customize vim, how do I get the line numbers to show up everytime i open up VIM.
0
votes
1
answer
202
views
Can you install both Vim 7 and Vim 8 on CentOS 7.9?
I teach classes that cover both Vim 7 and Vim 8. Is it possibly to install Vim 7 and Vim 8 together on CentOS? If so, how?
Everything I've have looked at so far covers updating Vim 7 to Vim 8.
I ...
1
vote
2
answers
37
views
How to associate unix commands from vim, with all the files opened in a split window?
Lets say for example, I have 3 files opened in split windows in vim. And I have to changes the access permissions to each of them, then one way to do it, is to move my cursor to individual split ...
4
votes
3
answers
1k
views
Install Vim with +clipboard support but without Gvim?
My distribution comes with a minimal version of Vim. vim --version returns
-clipboard, so the * and + registers interact (copy/paste) with the
primary and clipboard do not work.
The resources I've ...
1
vote
1
answer
176
views
Vimtex: `latexmk` compiler gives "no file name specified" error even after a new buffer is written to a file
When I open a new instance of vim without any 'filename' argument and write some LaTeX code, I cannot just compile it to pdf with latexmk, because it needs a file to compile from. However, even after ...
2
votes
0
answers
119
views
Windows Vim overwrites WSL file mode
I'm using gVim on Windows to edit files in WSL2 Ubuntu via the \\wsl$ mapping. When I :write in Vim, it overwrites the linux file mode/permissions with 644/-rw-r--r--, no matter what the mode was to ...
1
vote
1
answer
255
views
Vim won't open unless I Ctrl+C [closed]
Having this strange problem, where when I do
vim ...some_file...
The shell will freeze until I send a signal <Ctrl + C>, and then the vim opens up properly.
I haven't touched anything (.vimrc, ....
-1
votes
2
answers
1k
views
How does one install a VIM plugin without a plugin manager?
I am new to vim, I watched this video and wish to give it a good try for a month to see how I like it.
I want to add the NERDTree plugin to my vim, I'm actually using NeoVIM:
NVIM v0.4.4
Build type: ...
0
votes
4
answers
3k
views
How to tell NeoVim to use “python” instead of “python3”?
Im using pyenv to administer my python versions (Im on Manjaro Linux) and the command for python on my system is python but nvim wants to use python3. How can I change it?
Error:
[coc.nvim] Error on ...
3
votes
1
answer
218
views
GUI support will not compile in latest from github
I'm using CentOS 7.5. I just did a git pull in my clone of the vim repo to the latest: last tag v8.2.2340. I'm trying to compile. No matter what I do, it will not compile for the GUI (which it's ...
1
vote
1
answer
69
views
Unknown function: strptime on Linux Mint [closed]
I was having trouble to make the following function to work on Linux machines, where +eval feature is found upon calling :version. The error message reads:
E117: Unknown function: strptime
The ...
1
vote
1
answer
293
views
ALE says packages of my project don't exist
I'm having this problem with ale where in java files, it sometimes gives an error message saying that some packages don't exist. However, I can run without any problems my projects once I compile them,...
0
votes
1
answer
128
views
Vim indentation different on linux and macOS
I'm using vim to write in C for college. My .c files need to abide to specific formatting rules. While I'm writing my files on Linux, the .c files will be evaluated on macOS. I noticed that any tabs ...
0
votes
3
answers
720
views
How to copy the selection to clipboard without the indentation that is relevant just in the full file, not in the selection?
With other words: How to copy selection without its root-level indentation?
Example:
How to copy this:
a
b
c
d
instead of:
a
b
c
d
I am using Neovim inside VS Code ...
3
votes
1
answer
1k
views
How do I use vim within a Unix pipe-line?
I can use vim / ex to grep a file using the following invocation:
ex -c'g/foo/p' -cq -s afile.txt
I'd really like to use a similar command to grep some text from stdin. I thought the following command ...
1
vote
2
answers
403
views
How to create regex group with dependency with earlier group via math operations
Imagine I have a file as follows,
10 10
10 11
...
10 20
20 20
20 21
...
20 40
40 40
40 41
...
I know simple regex such as
To search two numbers
/\d\+ \d\+
To search repeated numbers
/\(\d\+\) \1
My ...
6
votes
1
answer
744
views
vim, vimdiff, ex, view, rvim and rview: How do they start in a different way when they are symlinks to the same binary?
I just installed version 8 of Vim and notice in the bin directory of the install location that all the above mentioned programs point to the same binary – vim. Then, how does it know when I invoke ex ...
2
votes
1
answer
589
views
$TERM specific NeoVim configuration
I spend half the time in a TTY (Linux console as in Ctrl+Alt+F2) and the other half in a X session. Unfortunately the color scheme I use for NeoVim in the graphical environment on xterm does not look ...
1
vote
1
answer
65
views
Opening and compiling tex files in subdirectory
I am using Linux mint cinnamon. Let's say I have .tex file in the sub-directory ~/MyTexfiles/Integration. When I double click on the .tex file to open it, it opens in vim since vim is my default ...
1
vote
1
answer
147
views
parsing / lexing scriptout log file from gvim -w
I've been running gvim -w /dev/shm/vim_keystrokes for some time, to collect keystrokes for later analysis. But now I'm looking for some guidance on how to make sense of the binary log file. Here's a ...
2
votes
1
answer
133
views
How to change in gvim GTK file browser the default file mask wildcard (glob)?
In gvim the command :browse confirm e launches a GTK file browser. The default file mask in this window depends on the filetype from which the browse window is invoked. I would like to change that ...
2
votes
0
answers
342
views
get current vim mode inside vimscript code
I would like to be able to get the current usual mode of vim inside a vim script (and not only inside the statusline).
I need this functionality to build a vim script linked with ruby script to be ...
5
votes
0
answers
82
views
gvim: Make the mouse follow CTRL-W_j and CTRL-W_k
I run a Linux/GNOME laptop where the focus follows the mouse, and I have vim's mousefocus feature turned on, so the selected viewport follows the mouse, too. But when I try to switch viewports using ...
6
votes
2
answers
4k
views
How to change location of ~/.vim
I have Vim 7 installed from my distro's package manager, and I compiled Vim 8 from source. Vim 8 is all in /usr/local. Then I created a new directory in $HOME called ".vim8". I have all my Vim 7 stuff ...
1
vote
2
answers
437
views
vim highlighting doesn't set the right type for a new filetype
This is what I have in my /usr/share/vim/vim80/filetype.vim (the only mention of messages in the file) :
" Messages (logs mostly)
au BufNewFile,BufRead */logs/couchdb/{,.log}{,.[0-9]*,-[0-9]*} setf ...
1
vote
1
answer
1k
views
How to create a custom colorscheme in which define custom highlight group each of containing set of words?
Let's assume we want to create a custom colorscheme. For example, content of a custom colorscheme file ~/.vim/colors/mytheme.vim are as follows,
" syntax highlighting groups
hi Comment guifg=#007f7f
...
3
votes
4
answers
746
views
Vim search and replace "/" only from string between round bracket [duplicate]
I have string lets say
count number of elecment when tra(XYixe0/en_in/old)='mid/2' rise='corse/2'
I want to replace / from (XYixe0/en_in/old) to .
My output string should look like
count number of ...
3
votes
1
answer
99
views
Maps literally read < and > instead of the actual character
Situation
Entire .vimrc:
inoremap a <CR>
Action: user types ia to enter insert mode and type a
Expected result: a carriage return is entered into the document
Actual result: the characters &...