Category Archives: /dev/null

Disable KDE file dialog in Chrome

To disable the KDE File dialog in Chrome Unstable, set NO_CHROME_KDE_FILE_DIALOG=1 as environment variable. Here is the code reference.

Generating static verison of CodeIgniter website

I love CodeIgniter and I love how easy it is to generate static version of your website. You just have to overwrite the _write_cache function in the Output.php class and turn the caching on. Here’s my version:

Creating ebook with Markdown, pandoc and GNU Make

Writing bok with markdown is pure joy. I started a short practical SQL tutorial yesterday and it started do get traction today. I used shell script at first to generate the static HTML page for the book but make looked like a better idea. Here is the Makefile I use:
BUILDDIR = ./build
.PHONY: clean spell
all: html epub
html: [...]

Great waterfall

I created a test page full of badges and counters and that’s what came out as waterfall diagram:

The whole report is here.

Resize column in postgres without recreating

A nice hack for postgres field size: http://sniptools.com/databases/resize-a-column-in-a-postgresql-table-without-changing-data

75% discount on HostGator only today

Today HostGator is offering 75% discount for hosting with code: 75OFF

Playing with big files

If you’re looking for a big text file to play with, why don’t you try http://www.dotnetdotcom.org/.
We invite you to help us share the content of internet by downloading the first part of our index. It has roughly 600,000 pages and is shared in an easy to parse text file. We are making this available [...]

Rating for Blogger (Blogspot)

If you want to add rating system for your posts in Blogger, check Outbrain (http://www.outbrain.com/). They have fully automated script for that.
I’m using it form my animated gifs blog.

Media Wiki Bot

I needed a bot to quickly modify the pages of wiki.muonlinehelp.com. So I created Mutex which kind of helps do the job. It’s full of bugs with no error handling but works for me.
Usage:
 
<?
require ‘class.mediawiki.php’;
$mw = new mediawiki(’http://yourwikiurl/api.php’);
$mw->login(’bot_user’, ‘bot_password’);
$mw->editPage(’title’, ‘page_text’);
?>
 
You can get the source code from here. [...]

chomp for bash

Bash doesn’t have chomp command but you can use tr to get rid of \n \r (and other) characters.