“I think this summarizes everything.” — mnmal
Go comes with a syntax file for vim (in misc/vim). I had to tweak ~/.vimrc a bit to make it work nicer. noexpandtab will force vim to insert tabs instead of spaces, smartindent makes the editor keep new lines at the same level of indendation as the previous line.
augroup golang
au!
au BufRead,BufNewFile *.go set filetype=go
au FileType go set noexpandtab
au FileType go set smartindent
au FileType go set equalprg=gofmt
augroup END
Professors often provide a page with links to lecture slides in PDF format. The main benefit of joining them to a single document, is that one can use a reader’s search function to find topics and keywords faster than when searching in multiple documents.
A script for people who want to develop for Real VMX, a VxWorks-like operating system kernel. The script installs ext2, GRUB, and a vanilla kernel to a small (32 MiB) QEMU image.

Some features of Real VMX:
Real VMX is licensed under the LGPL.
Get the script here! (only tested in Linux)
Consider a countdown program.
countdown.c:
#include <stdio.h>
#include <unistd.h>
int main(int argc, char **argv)
{
int seconds = 3;
for (int i = seconds; i != 0; --i) {
printf("%i... ", i);
fflush(stdout);
sleep(1);
}
puts("Go!");
return 0;
}
The goal is to put the actual countdown code in a macro. It fits perfectly in a function, but a macro is used for illustration purposes.
This article describes how content can be added to Tumblr using Javascript, and the jQuery library. The reader should be familiar with web development.
A Simplified Theme
<html>
<head>
<title>My Tumblr</title>
<script type="text/javascript" src="http://example.org/jquery.js"></script>
<script type="text/javascript" src="http://example.org/tumblr-dyn.js"></script>
</head>
<body>
{block:Posts}…{/block:Posts}
<p id="quote-of-the-day" style="display:none"></p>
</body>
</html>
We shall add a quote to #quote-of-the-day for permalink views.
tumblr-dyn.js
var isSinglePostView = function() {
var loc = document.baseURI;
var re = new RegExp(".*mytumblr.example.org/post/.*");
return loc.match(re) != null;
}
$(window).ready(function() {
if (isSinglePostView()) {
var qotd = $("#quote-of-the-day");
qotd.html(
'"You should\'ve seen the look on her face. It was the same look ' +
'my father gave me when I told him I wanted to be a ventriloquist."' +
' – George Costanza');
qotd.css('display', 'block');
}
});
You can use this approach to add custom content depending on what page the user is viewing.
An SSH gateway can be used where multiple hosts share the same IP address, where it isn’t possible, or acceptable, to use separate ports for the hosts’ SSH daemons.