Archive for November, 2009

Vim Syntax File for go

November 22nd, 2009 1 comment

While installing go, configuring vim syntax took longer than it should – would have been easier if I had known the following:

mkdir ~/.vim/ftdetect and ~/.vim/syntax if they don’t exist
vi ~/.vim/ftdetect/go.vim
au BufRead,BufNewFile *.go set filetype=go

copy go.vim to $GOROOT/misc/vim/go.vim to ~/.vim/syntax/

And of course, make sure you are running vim-enhanced and not vim-tiny, as tiny doesn’t support syntax highlighting.

Categories: Uncategorized Tags:

Determine Ubuntu Filesystem Type

November 7th, 2009 No comments

Ever connected a hard disk to your computer without knowing how the partitions are formatted, or even what type of formatting? This surprisingly hard-to-find utility reveals all:

/usr/lib/klibc/bin/fstype /dev/sdb1

just replace sdb1 with your drive.

fstype prints something like this:


I have no idea why the hide this under /usr/lib/klibc/bin. Other applications in the klibc-utils package get mapped to more reasonable locations.

Categories: Uncategorized Tags: