Vim Autotemplates
When I create a brand new file in Vim, I automatically insert template text into it. For Java, the template looks like this: public class CLASS { CURSOR } The C template looks like this: #include <stdio.h> #include <stdlib.h> int main(int argc, char **argv) { CURSOR return 0; } The HTML template looks like this: […]
You won’t believe what happens when you type these 19 things into Vim!
A student group at my university asked me to come talk about Vim at their upcoming meeting—which was two days away. I said no. Then they wised up and asked me to speak at a meeting sometime next semester. I said okay. Following are 19 of my favorite Vim editing tricks. Insert Mode Complete filenames […]
Quick Commenting in Vim
Speedy commenting is a major feature of any IDE like Vim. I’m sure there are good plugins that support it, but I don’t like other people’s code. I wrote my own, and here it is, ready for you to not like it. It works on the premise that for each type of file you have, […]
iMessage “DoS” Attack
I would be surprised if I’m the only student in this program who thinks small hacking pranks and minor harmless attacks on unsuspected folks are both fun and educational. This weekend I learned AppleScript, which for the Mac OS X-impaired folks, that’s a really nice scripting editor that comes standard on all OS X machines. […]
Automatic Alias Creation in Mutt/Vim
A friend has got me thinking about using Mutt again. I gave it up years ago after I was forced to use IMAP for one of my mail accounts, and I didn’t think Mutt was up to the task. I switched to Thunderbird, which lets me do certain things faster. However, I’ve really missed a […]
Restoring the Last Known Cursor Position in Vim
In unconfigured Vim, the cursor is placed at the beginning of each file that I open. When I close a file in Vim and open it again later, it’d be really nice if the cursor would automatically move to where I left off editing. And it can, with this handy autocommand: Autocommands let you write […]
Swapping first_second to second_first in Vim
When I write C code, I never know how to name functions. In an object-oriented language, my methods are verbs: add, insert, get, swashbuckle, and so on. The subject or indirect object of these verbs is an instance of the containing class, making my code read like English sentences: vector.add, list.insert, image.get, swashbuckler.swashbuckle. In C, […]
455 Programming for Mac Users
Hey there, If you’re on a Mac in CS 455, good for you. You’re spared much pain and hardship using VisualStudio. I kinda hate it. Thankfully, Xcode is your friend, and Apple is more than happy to have you come use it instead of Microsoft’s junk. You don’t need to be a paid developer for […]
Accessing thing-[012] from Mac OS X
Hey folks, I thought I’d follow up Dr. Johnson’s tutorial with my own, for Mac OS X users. I posted a brief (2 minute) video on YouTube of how to go about doing this. It’s super easy….and you won’t believe it’s not butter! Here’s the video! [youtube http://www.youtube.com/watch?v=7h29bKyPpr8?rel=0] Go get ’em
Accessing thing-[012] from home
Intro This short post will help you access the things and dplsubmit from home. For now it will focus on the Windows environment, but I may expand it to include screenshots from Linux too (sorry Mac, u no can haz tutorial). Step 1: Install Cisco AnyConnect and connect to UWEC’s VPN NOTE: The following should […]