Questions tagged [vimscript]

Vimscript is the scripting language built into the text editor Vim. It can also be referred to as "Vim Language" or "VimL".

Filter by
Sorted by
Tagged with
2
votes
2answers
46 views

Turning relativenumber option off/on when opening/closing the gdb terminal window

When I was not sure about how to do this, I asked this question on StackOverflow, the body of which is the following: As regards line numbers, when doing normal file editing, I prefer to have the ...
2
votes
0answers
33 views

Vim. Displaying register's content in a side bar

I have written a vimscript for learning purposes. The script displays the content of registers in a side bar by polling all registers periodically and redrawing the side bar when any changes happens. ...
2
votes
0answers
14 views

auto-fold deeply nested parts of a file (vimscript)

Folding in vim has bugged me for a while. What I intuitively want is for the details to be folded, but the overall structure of a file to remain unfolded. This way I can navigate around a file to see ...
4
votes
1answer
43 views

Cycle through filenames in vim

So I have a list of files which names are something like this ...
4
votes
0answers
113 views

Python breakpoints in Vim (Vimscript)

I recently decided that putting strategically placed print statements scattered about my python programs to debug was getting to be a little messy. I had thought ...
2
votes
0answers
40 views

Vim plugin for folding markdown lists

My first delve into vimscript was writing a plugin for folding markdown lists. I reckon there are a few idioms I'm missing here, so I would greatly appreciate any comments to improve the plugin. I'...
2
votes
0answers
80 views

VIm function that runs file through shfmt

I've written a Vim function that formats the file using shfmt. I'd like to know if there is a way I can improve this script. I am bothered by the fact that I can't think of a way to do this without ...
1
vote
0answers
44 views

A vim plugin to manage and view tag files

I'm writing a Vim plugin to manage and view tag files. There are two primary goals: gaining a bit more control over Easytags plugin by instructing it where to search and place tag files, and viewing a ...
3
votes
0answers
17 views

Scroll offset (vimscript)

When you jump to a search result in Vim, your cursor can end up near the bottom (or top) of the window, making it difficult to see the surrounding context. Some people like to automatically center ...
1
vote
0answers
94 views

Vim commands for browsing git history of a file

I've been working on this mostly for myself until now, but I am now thinking that it might be worth uploading for other people to use. But first I wanted to ask what other people think because I don't ...
2
votes
0answers
32 views

dyon vim syntax plugin

I recently made vim-dyon which is a syntax highlighter and indenter for the dyon programming language. There are probably some issues with being absolutely correct (since I am not too familiar with ...
8
votes
1answer
182 views

Map command in VIM

Background I've just started using VIM and have become comfortable with navigation. I'm attempting to reduce repetitive tasks and thought I would take a crack at mapping. I was able to accomplish my ...
3
votes
0answers
75 views

Scraping paths from a Gruntfile

As a part of my Tabv Vim plugin (which at this stage is nothing more than a pitiful rag-tag assortment of half-baked hacks), I have a function which attempts to guess the directory paths for main ...
2
votes
1answer
93 views

Checking if a git repository needs to be updated

I made a small Vim distribution that uses vundle. I decided to make a small function that checks if the repository must be updated. ...