What is this?
This is a small collection of random snippets of vimscript I've written while supporting users in #vim on freenode or on StackOverflow. They will be collected here for easier reference in the future.
Please note that these scripts aren't 100% foolproof and are generally just proof-of-concept demonstrations. The goal here is merely to show simple examples of what can be done in a few lines of vimscript.
You did something stupid, this is how it should have been done.
If you would like to suggest an improved or simply improvised version of any of these scripts I will gladly add alternatives and make sure you are credited.