Archive

Archive for August, 2010

Common Programmer Mistakes

August 26th, 2010 No comments

I for my sins code in PHP,Perl,ColdFusion using database MySQL and also write JavaScript, XML and battle with CSS and Ajax etc. Often I’m working on these projects in parallel which gets kind of stressful. Anyway I let my standards slip recently and made the following mistakes and suffered for it.

  • Not immediately taking my own backup of the files I was working so I could rollback at any time and as importantly prove whether my changes had or had not caused a regression or bug
  • Leaving test files lying about, so I later got confused as to which was the actual version
  • In Perl coded the catastrophic error $restart=0 if $cnt=1; (should be if $cnt==1)
  • Also in Perl had some problems due to not systematically initializing variables in a subroutine
  • To my credit have started to useĀ  git for version control
Categories: Coding Tips Tags: ,

VIM 7.3 Released

August 22nd, 2010 No comments

Vim 7.3 is a stability release integrating hundreds of patches. It does contain however some new enhancements.

The most notable additions since 7.2:
– Persistent undo and undo for reload
– Blowfish encryption, encryption of the swap file
– Conceal text
– Lua interface
– Python 3 interface

Persistent undo is probably the feature which most interests me. This allows you to undo changes you made last time you edited a file; a feature which must be used with some care obviously!. It works by saving the changes in a temporary file. A file is created for each file you modify, to avoid cluttering up your directories you can configure vim to use a special directory.

Download the latest VIM here vim.org/download.php

Windows Users can go directly to this link ftp://ftp.vim.org/pub/vim/pc/gvim73.exe which is the simplest way to upgrade. By the way REMEMBER to backup your .vimrc file!!!

Recently I’ve been using the Cream version http://sourceforge.net/projects/cream/files/Vim which maintains an up-to-date single click install version of VIM with all patches it is already at version 7.3.3. And just to confirm this is the version without Cream.

Categories: vim Tags: