many website like tripadvisor.com or lastminutes.com pull the information from CDS. One free provider is Kayak.com but usage is restricted to 1000 queries/day.
global distribution system (CDS)
October 1, 2009 by paragasujquery open new window on external links
September 30, 2009 by paragasu$("a:not([href^='http://www.exampleuri.com']): not([href^='#']):not([href^='/'])").attr("target","_blank");
ncftp – upload recrusive files
September 25, 2009 by paragasuto upload the whole directory and subdirectory
$ncftpput -u <username> -p <password> -R <host> <remotedir> <localdir>
Bucardo – Asynchronous PostgreSQL Replication System
September 25, 2009 by paragasuBucardo is an asynchronous PostgreSQL replication system, allowing for both multi-master and multi-slave operations. It was developed at Backcountry.com by Jon Jensen and Greg Sabino Mullane of End Point Corporation, and is now in use at many other organizations.
E319: Sorry, the command is not available in this version: syntax on
September 7, 2009 by paragasuif you get this error when trying to enable syntax highlighting in vim,
#apt-get install vim
css rounded corner
September 3, 2009 by paragasu
.roundcorner{
border-radius:6px; /*css3 - but not supported yet*/
-webkit-border-radius: 6px; /*mozila - firefox, iceweasel */
-moz-border-radius: 6px; /*webkit - google crome, midori, safari */
}
and more
-moz-border-radius-topleft / -webkit-border-top-left-radius
postgresql add on delete cascade to foreign key
September 2, 2009 by paragasu
ERROR: update or delete on table "page" violates foreign key constraint "info_page_id_fkey" on table "info" DETAIL: Key (page_id)=(106) is still referenced from table "info"
you have to drop cascade and recreating the new one.
psql> \d info
psql> alter table info drop constraint info_page_id_fkey;
psql> alter table info add constraint "info_page_id_fkey" foreign key(page_id) references page on delete cascade;
chess in debian
August 9, 2009 by paragasuCrafty, developed by Robert Hyatt, is a descendant of the Cray Blitz chess engine that was the World Computer Chess Champion from 1983 to 1989.
to install
#apt-get install crafty xboard
start the game with
$xboard -fcb 'crafty' -fd crafty_directory
book off — This options disables the use of opening book for crafty.
ponder off – Crafty can’t think while you are playing your move.
st 1 — Make the maximum thinking time for Crafty just one second.
sd n — Crafty won’t think more than n moves ahead.
If you are able to beat crafty too often, you can also make it more stronger with these options:
hash nK — Makes the hash table bigger
hashp n — Makes the hash table for pawns as large as possible
it hard to bet.
login to SSH with keys
August 6, 2009 by paragasu
$ssh-gen -t rsa
$ssh-copy-id username@server
$ssh-add ~/.ssh/id_rsa