Dejan Ranisavljevic

web developer (PHP, MySQL, Javascript)

On ubuntu if you try to compile php with imap you will probably get error like this:
configure: error: utf8_mime2text() has new signature, but U8T_CANONICAL is missing

So what you have to do is, install libc-client-dev:
sudo apt-get install libc-client-dev

after that you can configure your php with:
./configure --with-imap --with-imap-ssl --with-kerberos

I hope this will help someone cause i had a lot of headaches setting this up.

The subversion version control system has a wonderfully handy feature called hooks. Hooks are essentially bash scripts that are triggered by a version control event (such as a commits, or revision property changes).

JSLint takes a JavaScript source and scans it. If it finds a problem, it returns a message describing the problem and an approximate location within the source. The problem is not necessarily a syntax error, although it often is. JSLint looks at some style conventions as well as structural problems. It does not prove that your program is correct. It just provides another set of eyes to help spot problems.

Stoyan Stefanov wrote a helpful blog post describing how to create a simple TextMate bundle that allows you to quickly run the current file through JSLint, and validate your javascript code if there is some error.

So after running jslint textmate bundle you will see something like this if some error occurs:

textmate jslint validation

If you want to send SMTP mail via localhost on Mac OSX Leopard. One way is doing it with postfix. So lets enable postfix. As OS Leopard is already comming with postfix all you have to do is make him autorun.
Edit the plist file to start postfix automatically on boot:
sudo mate /System/Library/LaunchDaemons/org.postfix.master.plist
With the plist i [...]

Sometimes the working copy metadata format changes incompatibly between minor releases. For example, say you have a working copy created with Subversion 1.4.4, but one day you decide to try out Subversion 1.5.0. Afterwards, you attempt to switch back to 1.4.4, but it doesn’t work — it just gives the above error.

This is because 1.5.0 upgraded your working copy format to support some new features (in this case, changelists, the keep-local flag, and variable-depth directories). Although 1.4.4 doesn’t know anything about these new features, it can at least recognize that the working copy format has been upgraded to something higher than it can handle.

Checkout nice articles from Nikolai Onken, about profiling javascript with dtrace and firefox on osx.

Firefox on OSX with dtrace Part I
Firefox on OSX with dtrace – Part II

Even faster giting now with bash completion. The contained completion routines provide support for completing:

  • - local and remote branch names
  • - local and remote tag names
  • - .git/remotes file names
  • - git ’subcommands’
  • - tree paths within ‘ref:path/to/file’ expressions
  • - common –long-options

Typing git branch over and over to see what branch you are on know to be boring sometime. So set up your shell to always put the name of the current branch into your prompt.

bash with git branch