Friday, 4 April 2008

etymology of jargon

etymologically interesting

Anything self-referential is amusing (blame/praise starts with GEB - how can one describe systems purely if you have any use/reference of anything in that system in the description of the system - HAHAHAH!) like a joke or pun. Etymology of words about language, jargon: old french jargon garrire bird-chatter gargle. from http://www.etymonline.com/index.php?term=jargon

http://catb.org/jargon/html/introduction.html
http://catb.org/jargon/html/distinctions.html
"communication, and of inclusion, and of exclusion."
And for hacker jargon as a technical language there is a complex level of detail which does seperate it from being just a plainer slang. Not easy to learn/understand unless you learn the whole culture (shared consciousness), descriptive of complex/different ideas/models/thinking... which is very useful and important for facilitation of communication, quite like a real language.

Oh yeah! so elitist :) too.

"we have attempted to ensure that everyone's sacred cows get gored, impartially. Compromise is not particularly a hackish virtue, but the honest presentation of divergent viewpoints is."

This digression started with http://www.faqs.org/docs/jargon/H/hexadecimal.html
"correct term for base 10, for example, is ‘denary’"


~"etymologically pure"~ real live language decimal style words "too racy and amusing for stuffy IBM", (incorrect and inconsistent anyway! :))
2 binary binary
3 ternary or trinary ternary
8 octonary octal octaval
10 denary decimal decimal
16 sendenary hexadecimal sedecimal sexadecimal


Numerical Prefixes: http://phrontistery.info/numbers.html
numerical words in English (possibly common to many languages via maths ?) (mainly from greek and latin )
see Table 1: Latin-Prefixed Numerical Words
see Table 3: Latin Numerical Words: 13 to 1000

Numbers from 1 to 10 in over 5000 languages: http://zompist.com/numbers.htm

Arabic wāhid iŧnān ŧalāŧah 'arba`ah xamsah sittah sab`ah ŧamāniyyah tis`ah `ašarah
Cantonese jat i sam sei ŋ lok tshat pat kau sap
Dutch een twee drie vier vijf zes zeven acht negen tien
English one two three four five six seven eight nine ten
French un deux trois quatre cinq six sept huit neuf dix
German eins zwei drei vier fünf sechs sieben acht neun zehn
Greek éna đío tría téssera pénde éksi eftá oxtó ennéa đéka
Hindi/Urdu ek do tīn cār pā~c chai sāt āth nau das
Irish aon dó trí ceathair cúig sé seacht ocht naoi deich
Italian uno due tre quattro cinque sei sette otto nove dieci
Japanese ichi ni san shi go roku shichi hachi ku juu
Mandarin(Beijing) yi er san si=sz wu liu qi ba jiu shi
Polish jeden dwa trzy cztery pięć sześć siedem osiem dziewięć dziesięć
Runic+ æinn tvæiR þrīR fiūriR fæ:m sæx siū ātta nīu tīu
Russian odín dva tri četýre pyat' šest' sem' vósem' dévyat' désyat'
Spanish uno dos tres cuatro cinco seis siete ocho nueve diez




Heh heh :) warhammer again in comics:
http://ars.userfriendly.org/cartoons/?id=20080403
http://www.weregeek.com/2008/03/03/

Thursday, 3 April 2008

library-check.pl, postfix config to forward/relay mail to smtp server

1. Move across library-check.pl script from suse to ubuntu
2. enable mail from command-line and perl WWW::Mechanize script dependancies
3. solve postfix trouble (i.e. config postfix properly)
4. WAH! 5 + 6 books two accounts 5*23 + 6*29 days overdue. oops.


# Helpful reading:
Relaying Mail to a SMTP Server That Requires Authentication (Ubuntu/Postfix)
http://www.finefrog.com/2008/02/15/relaying-mail-to-a-smtp-server-that-requires-authentication-ubuntupostfix/
http://www.marksanborn.net/linux/send-mail-postfix-through-gmails-smtp-on-a-ubuntu-lts-server/
http://ubuntuforums.org/archive/index.php/t-67397.html
http://www.wormbytes.ca/articles/postfix-with-sympatico-relay
http://www.postfix.org/docs.html


O=/mnt/suseold
export http_proxy=
export https_proxy=
sudo apt-get install mailutils
sudo cpan -i WWW::Mechanize
sudo cp $O/usr/local/bin/library-check.pl /usr/local/bin/
sudo cp $O/etc/cron.daily/run_library-check.sh /etc/cron.daily/
sudo cp $O/etc/cron.daily/run_library-check-fionnuala.sh /etc/cron.daily/


# postfix setup took me a couple of hours - arg!
# simple postfix setup just to forward/relay mail to smtp server (which needs authentication)
# set some vars for use just in commands below
MYSMTPSERVER=www.smtpservername.com
MYACCOUNT=myaccount
PASSWORD=password
MYACCOUNT_SERVER=smtpservername.com
MYEMAIL=${MYACCOUNT}@${MYACCOUNT_SERVER}

# this was the thing I did last which started everything working (and uncomment myorigin = /etc/mailname in /etc/postfix/main.cf):
echo $MYSMTPSERVER > /etc/mailname

sudo vim /etc/postfix/mail.cf

# uncomment this:
myorigin = /etc/mailname

# add relay host with location of passwd info
relayhost = [<MYSMTPSERVER>]

smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl/sasl_passwd
smtp_sasl_security_options = noanonymous

smtp_always_send_ehlo = yes
smtpd_sasl_local_domain =
smtp_sasl_tls_security_options = noanonymous

# comment this line out:
#myhostname = <MYACCOUNT_SERVER>


# store smtp authentication details for postfix use
sudo mkdir /etc/postfix/sasl/
echo "${MYSMTPSERVER} ${MYEMAIL}:${PASSWORD}" > /etc/postfix/sasl/sasl_passwd
postmap /etc/postfix/sasl/sasl_passwd
rm /etc/postfix/sasl/sasl_passwd # I think.
# but ACTUALLY I notice the hash did not seem to work? can still see info unhashed in /etc/postfix/sasl/sasl_passwd.db ?


/etc/init.d/postfix restart


# log of successful send:
tail -1550f /var/log/syslog |grep -v atkbd.c

Apr 4 02:08:29 <MYHOSTNAME> postfix/pickup[12695]: 6320E454092: uid=1000 from=<<MYACCOUNTNAME>>
Apr 4 02:08:29 <MYHOSTNAME> postfix/cleanup[12700]: 6320E454092: message-id=<20080404010829.6320E454092@<MYHOSTNAME>.localdomain>
Apr 4 02:08:29 <MYHOSTNAME> postfix/qmgr[12696]: 6320E454092: from=<<MYACCOUNTNAME>@<MYACCOUNT_SERVER>>, size=384, nrcpt=1 (queue active)
Apr 4 02:08:30 <MYHOSTNAME> postfix/smtp[12702]: 6320E454092: to=<<MYACCOUNTNAME>@<MYACCOUNT_SERVER>>, relay=<MYSMTPSERVER>[<MYSMTPHOSTIP>]:25, delay=1.2, delays=0.03/0.01/1.1/0.06, dsn=2.0.0, status=sent (250 OK id=1JhaPy-00073e-6f)
Apr 4 02:08:30 <MYHOSTNAME> postfix/qmgr[12696]: 6320E454092: removed



smtp auth failed
because smtp user is NOT <MYACCOUNTNAME>@<MYHOSTNAME>.localdomain
"550-Verification failed for <<MYACCOUNTNAME>@<MYHOSTNAME>.localdomain> 550-Unrouteable address"
This is solved by having smtp server name in: /etc/mailname

Apr 4 02:05:35 <MYHOSTNAME> postfix/pickup[12551]: 04E56454092: uid=1000 from=<<MYACCOUNTNAME>>
Apr 4 02:05:35 <MYHOSTNAME> postfix/cleanup[12556]: 04E56454092: message-id=<20080404010535.04E56454092@<MYHOSTNAME>.localdomain>
Apr 4 02:05:35 <MYHOSTNAME> postfix/qmgr[12552]: 04E56454092: from=<<MYACCOUNTNAME>@<MYHOSTNAME>.localdomain>, size=404, nrcpt=1 (queue active)
Apr 4 02:05:36 <MYHOSTNAME> postfix/smtp[12558]: 04E56454092: to=<<MYACCOUNTNAME>@<MYACCOUNT_SERVER>>, relay=<MYSMTPSERVER>[<MYSMTPHOSTIP>]:25, delay=1.2, delays=0.03/0.01/1.1/0.03, dsn=5.0.0, status=bounced (host <MYSMTPSERVER>[<MYSMTPHOSTIP>] said: 550-Verification failed for <<MYACCOUNTNAME>@<MYHOSTNAME>.localdomain> 550-Unrouteable address 550 Sender verify failed (in reply to RCPT TO command))
Apr 4 02:05:36 <MYHOSTNAME> postfix/cleanup[12556]: 2AB34454093: message-id=<20080404010536.2AB34454093@<MYHOSTNAME>.localdomain>
Apr 4 02:05:36 <MYHOSTNAME> postfix/bounce[12559]: 04E56454092: sender non-delivery notification: 2AB34454093
Apr 4 02:05:36 <MYHOSTNAME> postfix/qmgr[12552]: 2AB34454093: from=<>, size=2580, nrcpt=1 (queue active)
Apr 4 02:05:36 <MYHOSTNAME> postfix/qmgr[12552]: 04E56454092: removed
Apr 4 02:05:36 <MYHOSTNAME> postfix/local[12560]: 2AB34454093: to=<<MYACCOUNTNAME>@<MYHOSTNAME>.localdomain>, relay=local, delay=0.02, delays=0.01/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)
Apr 4 02:05:36 <MYHOSTNAME> postfix/qmgr[12552]: 2AB34454093: removed

Wednesday, 26 March 2008

Bill Coleman new music

Went out with P&P to see Bill in Doyles Ruby Sessions last night.
He has sprouted quite a healthy beard. And gotten 15 red t-shirts plus red-striped
band trousers. :) Slightly poorer than before with working part-time but lots of time for music.
He had last two weeks off completely from work and played 4 I think brand-new shiny songs.
I was very impressed, crowd was entranced - completely silent a few times - noticable when the music goes softer. COOL. I get blown away with the sounds and it's tremendously emotionally engaging.

Hard to describe new songs.
One of them was made in 12hrs and making was filmed for someone and it's
sent in as a pilot to rte for a musicians-compose song in 12hours type tv series.
Two of them using the voice/music capture and playback and sing/play in loop with self thingumbyjig.

http://www.myspace.com/billcolemanmusic

http://bcoleman.songwriter.ie/news.htm

A couple of Dublin ones, Purty kitchen next Sun. Supporting Gary Dunne releasing something, ...

Busy in work. Over Easter merged queue of things waiting for merge (with a few fixing of silly broken build things) and rollover tests to new versions.

BC - Bill Coleman - BC - Bag of Chips - BC - Bag of Cats - BC - Butterfly Caterpillar - Bill Coleman - BC - Big Cheese - BC - Bat Cave - BC - Big Chief - BC - Bad Cat - BC

Friday, 21 March 2008

sudo tachet i tac a ti

G: Ehi tu, tachet i tac a ti!
L: Io tachet i tac a ti, che te tachet it tac? Tachet i ti i to tac.
G: sudo tachet i tac
L: okay

Fionnuala got me that http://xkcd.org t-shirt for Christmas :)

sudo solve impossible problem

Thursday, 6 March 2008

best leaving present EVER: The Gemmalarm™!

Gemma is leaving us and one of the things she gets is this:
http://www.gemmalarm.com/ The Gemmalarm™

The Gemmalarm™ itself is the best ever office utility/joke.
Gemmalarm™ = orrible app -> parallel port -[wires]-> picture of us with leds for eyes.

Monday, 25 February 2008

scales balancing puzzle check weights40.pl

see perl script weight40.pl


#!/usr/bin/perl

=head1 NAME

weights40.pl - check you can make each weight from 1 to 40 balance

=head1 DESCRIPTION

This doesn't solve the puzzle but does prove that the solution works.

The puzzle is you have a balance (bilancia in Italian).
And you can choose some unit weights to help weigh things.
If you get any unit weight from 1 to 40 you need to be able to determine the weight.
(You have to make the scales balance, you're not allowed to measure
it as lighter than w+1 and heavier than w-1 hence is w.)
What is the minimum number of weights you can do this in ?

If the puzzle is told properly then you probably have to bring the
balance and weights up a big mountain with dragons on top so you wish to use the absolute minimum
number of weights (or possibly minimum weight of weights - is it the same answer I wonder?)

=cut

my @weights = ( 1, 3, 9, 27 );

for(my $w=-1; $w<=41; $w++) {

# brute force, try balance all permutations, weights on both sizes

# try position of not there, left, right for each weight
my @weight_pos = ( 0, 0, 0, 0 );
my $wi = 0;

# print terrible message if not found otherwise might miss one
my $terribleness = "BAH! :( not good, no match for $w\n";
my $found = 0;

for($weight_pos[0]=0; $weight_pos[0]<3 && $found==0; $weight_pos[0]++) {
for($weight_pos[1]=0; $weight_pos[1]<3 && $found==0; $weight_pos[1]++) {
for($weight_pos[2]=0; $weight_pos[2]<3 && $found==0; $weight_pos[2]++) {
for($weight_pos[3]=0; $weight_pos[3]<3 && $found==0; $weight_pos[3]++) {

# start with $w always on left
my $left_tot = $w;
my $right_tot = 0;
my @leftside = ( $w );
my @rightside = ();

# print '$#weights is ' . $#weights . " (number of elements in weights array)\n";

# put weights on balance
for($wi=0;$wi<=$#weights;$wi++) {

#print "dbg w=$w wi=$wi pos=$weight_pos[$wi]\n";

if ($weight_pos[$wi] == 1) {
#printf "L";
push @leftside, $weights[$wi];
$left_tot += $weights[$wi];
} elsif ($weight_pos[$wi] == 2) {
#printf "R";
push @rightside, $weights[$wi];
$right_tot += $weights[$wi];
}
#$ls += "(".$weights[$wi].) ";
#$rs += "(".$weights[$wi].) ";
}


#print "dbg w: $w, balance $left_tot = $right_tot, left: @leftside - right: @rightside\n";

if ($left_tot == $right_tot) {
print "w: $w, balance $left_tot = $right_tot, left: @leftside - right: @rightside\n";
$terribleness = "";
$found = 1;
break;
}

}
}
}
}

print $terribleness;
}



perldoc is a good reference, (command-line interface to perl docs)
not on all machines but is on slaine
same stuff as is on web in lots of places of course:
http://perldoc.perl.org/perl.html

e.g. perldoc perl, perldoc perldoc (for table of contents)
perldoc perlsyn
perldoc perlre

-f or -q to get function documentation or search faq:

perldoc -f printf
perldoc -q while

After you know all that perldoc then you can start thinking about using perl modules! :D


To read perl documentation _inside_ perl scripts or modules just do e.g.:

perldoc weight40.pl

Saturday, 23 February 2008

"Oh ye broke me cups and saucers"

I've set me playing the recorder of the tune of "cups and saucers" as ringtone for Mum :)
I started with "Moll Dubh" for Fionnuala.
Quite a striking mobile ringtone! :-o

Mum remembers her dad singing this chorus, and only the chorus:

Oh ye broke me cups and saucers
Oh ye did ye rogue, oh ye did ye rogue
Oh ye broke me cups and saucers
Oh ye did ye rogue, oh ye did ye rogue

Much grepping of internet reveals those lyrics are nowhere!
Maybe on an album by Bobby Gardiner - The Clare Shout - song The Kerry Cow, Cups and Saucers
http://www.thesession.org/recordings/display/2330
Someone says on comments "It's called Cups and Saucers on Bobby Gardiner's album "The Clare Shout". He lilts the tune and runs it into the song "Cups and Saucers" (of the same tune).
Maybe that is song eilzab is talking about."

thesession.org seems to be quite a good source for information on irish tunes.
lyrics, sheet music and ABC music
http://www.thesession.org/tunes/display/1123
Also known as "Bhiosa La I BPort Lairge", Cups And Saucers, False Knight On The Road, The False Knight On The Road, I'll Cloot My Johnny's Breeches, Let's Pet The Pope, Little May Cullinane, O, I Courted A Farmer's Daughter, Port Lairgè, Portlairge, Portláirge, Dashing White Sergent, White Cockade

And in last.fm/youtube can find various renditions of "The False Knight on the
Road" ... and one or two of them have the same tune.
http://www.last.fm/music/Steeleye+Span/_/False+Knight+On+The+Road+%5Blive%5D