Swaroop C H

blog books about contact subscribe

Connect the text

09 May 2005

A while ago I was thinking about using a wiki to organize my notes, but I don't know if even that scenario would be useful for quick note taking because of the conversion from wiki syntax to HTML everytime which causes a lag when saving the notes.

I have found a simple and effective solution (next to paper and pen, which I would always prefer) by using VIM with the Universal Text Linking plugin and the Markdown syntax file.

As the name indicates, the Universal Text Linking (or UTL for short) plugin allows you to create URLs that you can access like real hyperlinks (within VIM) and even opens a browser or media player depending on the type of file you link to.

I like using Markdown syntax because I find it to be the most cleanest and simplest of semantic text markup styles that I have used. So, the Markdown syntax highlighting makes the text even more pleasant to read.

Let me give an example on how I created a plain text wiki:

![13103132][Medium][]

I have one central file which acts like an index to the other documents and this is the first file I always open. I also put in any critically urgent, etc. stuff in this file, so I'm always reminded of it.

I have unimaginatively named this file as 'plan' and here are the contents of that file:

  • [ProjectA]
  • [MeetOnSaturday]

From here, I just press gu on [ProjectA] and it takes me to that file. So, I read or make changes to the notes on my top-secret project and then I just hit Ctrl-O and I'm back to my 'plan' file which I started with.

If you run set filetype=mkd for the file, you will get Markdown syntax highlighting. Better yet, just put a modeline such as # vim: filetype=mkd as the last line of the file and VIM will automatically do this for you everytime.

In effect, you have a wiki using just plain text!

I think I must be catching the Wikiphilia.

Sidebar: I have let mapleader="," in my vimrc file, so I press ,gu to open links. I find the comma easier to type than the backslash.

Comments

Vikram Sujanani says:

Hi Swaroop,

After your earlier post 'http://www.swaroopch.info/archives/2005/04/08/yahoo-notepad-as-wiki/' I started using 'Viki/Deplate' as a personal wiki for Vim, and kept the wiki folder on flash drive.

Yours solution in this post too is nice, particularly since it provides for Markdown syntax.

By the way, I am intrigued by interesting color scheme you have in the Vim image and also the '> .> }> ]> characters in fold column !!!

Swaroop says:

Hey Vikram,
[Viki/Deplate](http://www.vim.org/scripts/script.php?script_id=861) looks really interesting. I love the part about export to docbook! I should take a look at it more.

The color scheme is `desert` in GVIM, I've become addicted to that scheme ;)

The fold column is because of the [ShowMarks plugin](http://vim.sourceforge.net/scripts/script.php?script_id=152) , it visually shows me the shortcuts where I can jump around in the file :)

Feedback

There's no comment box, but please do email me or tweet me your thoughts and criticisms, and I will publish the relevant ones here.