Howto disable iPhoto autostart when connecting an iPhone ?

Finally I found an awnser:
NOTE: This is only for Mac, I don’t know how to do it on a Windows machine.

1. connect your iPhone to your Mac
2. close the starting iPhoto for the last Time 😉
3. open up the “Image Capture” (eng) / “Digitale Bilder” (de) Application
4. select your iPhone and choose “No Application” in the DropDown List.
5. close it and enjoy connecting your iPhone without the annoying autostart

iPhone 3GS jailbreak with purpler**n under os x 10.6 build 10A394

Today I had the chance to see and feel the speed of the new iPhone 3GS.
It’s awesome I think.

The guy that own’s this nice piece of technology want to jailbreak it. So we tried the new Tool called ‘purpler**n’.
My biggest concern was that the tool woudn’t work because that guys MacBook
is running 10.6 10A394. He told me that there are a lot of applications that still
does not work under SnowLeaopard. So let’s try…

1. download purpler**n

2. start it and see … it works fine

3. Click the button and wait till iPhone restarts

4. open the “Freeze” app on your iPhone

5. click Download Cydia

6. wait until “Download, Unpakced, Cleaned” and finally “Finished!” appears on your screen

7. restart your iPhone and enjoy Cydia

Note: we didn’t need to unlock the sim card.

bible5

found this while reading about html5, it’s just great

From: Michael Penman
Date: Thu, 21 Jun 2007 07:31:58 -0500
To: www-html@w3.org
Message-Id: <20070621123158.E4D111CE303@ws1-6.us4.outblaze.com>

LOL!

——- Forwarded message ——-

Subject: WHATWG to start work on “Bible5”
Date: Wed, 20 Jun 2007 22:48:38 +0200

WHATWG to start work on “Bible5”

Silicon Valley – June 2008

After their successful work on HTML5, CSS5, XML5, SVG5, and Web5, the
WHATWG has announced that it has started work on a new version of the
Bible, to be called “Bible5”.

“Initially, one of the most obvious changes will be a change to the ten
commandments”, said Ian Hickson, the group’s leader and idealog. “For
instance we shall be changing ‘Thou shalt not kill’ to ‘Thou SHOULD not
kill’ with the necessary reference to RFC 2119. Clearly after a couple of
millenia experience with this spec, people have not been doing what the
spec requires, and so we are merely updating it, modernizing it you might
say, to reflect actual usage. I mean, what use is it having admonitions if
most people are not going to follow them?” he asked, adding “That was a
rhetorical question. I mean, what use is a spec that forbids things? It
just makes it harder for people to be compliant.” “That was also
rhetorical” he hastened to add.

Alan van Finckelstein, one of the people who will be initially working on
the spec, expanded: “One of the problems with the Bible is its
incompleteness” she said. “Although it mentions a few sins that are
forbidden, and a few that are apparently OK — incest in the case of Job’s
daughters being one that immediately springs to mind — it leaves hundreds
if not thousands of sins completely unspecified. We are currently using
Google to search for and identify all currently known and practised sins,
so we can include them in the permitted list.”

OPEN PROCESS

“One of the differences with the WHAT WG doing this work instead of the
closed and secretive Christians, is that we have a completely open
process” Hickson added. “Anyone can, and indeed does, join in. We are
currently asking the public to submit use cases of sins that they have
committed in the past, or would like to commit in the future, so that we
can add them to the spec.”

“Speed is another advantage” chimed in Alan. “The Christians took 325
years to produce their spec, before declaring a Rec at the Council of
Nicaea. Talk about slow! We think we can produce a new version in about
two weeks” she said.

“Of course, that will only be a working draft!” pointed out Hickson. “But
we hope to go to CR within a couple of weeks after that. We are preparing
the test suite at the moment. The spec will not go to Rec until we have
recorded evidence that every single sin has been committed at least twice.
Our current timeline shows that we anticipate staying in the CR phase for
about 325 years. We may have to go back to Working Draft after that
though.”

“It need hardly be mentioned,” laughed Finckelstein “that the Bible never
actually went through CR, which is just typical.” She went on “If it had,
it would never have reached Recommendation stage. It is riddled with
inconsistencies and errors, or things that have just not been defined. To
take an example, when Moses comes down the mountain with the ten
commandments and sees his people sinning, he loses his temper and smashes
the marble tablets — apparently smashing up God’s property was not on the
list of things thou shalt not do — and then initiates a killing spree of
three thousand of his followers. So much for ‘Thou shalt not kill’!”.

“Anyway,” concluded Hickson, “the big advantage of Bible5 will be that the
number of sinners and criminals will be reduced at a stroke. Just imagine,
the prisons will be emptied, and for the first time in history we will
have a completely law abiding society!”

WHAT’s next? Finckelstein: “Electrical wiring and plugs”, Hickson: “The
rules of the road; airline safety; oh there’s so much we can improve”.

###

picazza – image hosting

Today I had some spare time and finally set up the first version of my free image hosting. For now I called it picazza.
It can be found here:
here

  1. simple to use
  2. minimalistic
  3. free of any charge or advertisement
  4. anonym

I hope you enjoy using it.

those images are some of the first i’m hosting, I share them with you 😉
see my favorite here, and some others below.
picazza
picazza

awk and word frequencys

I have a list that I use for making gnuplots. The structure is the following

wordId wordWeight

e.g. 101 34.342 = Word with id 101 has a calculated weight of 34.342 times.

The bad thing is that this list is unordered. Now I wan’t to order this list getting the greatest weight and their corresponding word id. Bash doens’t seem to be the best solution for this so I made up my first awk script.

Here is it, it prints the most common word from file toPlot.stats.

awk ‘ BEGIN{ max=0; w=-1 } { if ( $2 >= max) { max=$2; w=$1 } } END{ print “id”,w,”has  most often with count of”, max; }’ toPlot.stats

and the output:

id 1545 has greates weight with  28199.40186090438

My file has 1.722.913 lines, execution time:

real    0m1.618s
user    0m1.576s
sys     0m0.032s

move svn repository with revisions

When moving your favorite svn repository from Server A to Server B there are several possibilities. I use the following way which I think is the best.

1. Create a dump

svnadmin dump your_repository/ > your_repository.svn.dump

2. Somehow transfert your ‘dump’ file to the Server B

3. Create new svn repository on Server B

svnadmin create your_repository

4. Load your dump

svnadmin load your_repository < your_repository.svn.dump

that’s it

#move more than one svn repository at once
for repo in $(ls /home/web/svn)
do
svnadmin dump $i/ > $i.dump
scp $i.dump cb0@ServerB:/svn/
ssh -t cb0@ServerB svnadmin create /svn/$i
ssh -t cb0@ServerB svnadmin load /svn/$i < /svn/$i.dump
done

synergy, ssh and port forwarding

How to use synergy over ssh with a gateway server, or
How to make port fowarding over a gateway ?

Ok then, someone last week showed me the great tool “synergy”. With it, two ore more computers can be controlled by one keyboard and one mouse. So that’s nothing new.
The nice thing is that if you move your mouse over the boarder of screen 1 if will appear on screen 2 just like this screen was connected to your computer.
It’s working great and I wanted to have this everywhere my MacBook goes.
Setup and Config is real easy and descibed at http://synergy2.sourceforge.net/

The problem is that it’s build upon a server client architecture and you need to have a direct connection between your server and your client. Yes well that should be no problem but I’m working in an office where the networks for hosted computers and the computers ones bring in  are seperated. The only option to get a connection from my macbook to the linux machine I’m sitting right next to, is a connection over a gateway Server that’s somewhere else.
So ssh from my macbook -> gateway
and then from gateway -> to office local linux box
But if i do it this way I won’t be able to establish a direct connection. After some research on the net I came up with this:
Box1 = MacBook
Box2 = Gateway Server
Box3 = office linux box

1st of all start the Server on Port 8033 (or sth. else), Type this on bash in BOX3

synergys -a localhost:8033 -f –config ../conf/synergy.conf

then make a port forwarding from Box2 port 8033 to Box3 port 22. Type this on bash in BOX1

ssh -L 8033:BOX3:22 cb0@BOX2

Then make a port forward from localhost port 24810 to port 8033 on localhost which redirects us directly to Box3. Type this on bash in BOX1

ssh -p 8033 -v -f -N -L localhost:24810:localhost:8033 cb0@localhost

Now on Box1 type this to connect synergy to localhost on port 24810 which redirects it to Box 3.

./synergyc -f localhost:24810

thats it.
Hope you enjoy your new productivity with synergy 😉

A nice project I thought of was to teach my macbook to atomatically connect to a specific server dependent on the enviroment i’m in. This should somehow be possible using apple script but at the moment I have no Idea how.

the sudden death of a hdd

Now I’m sure, it’s been over a week and finally there is no possability to restore anything from the hard drive.
After paying around 160€ for a new smaller main disk the AASP told me that he was not able to save any data and that the hdd even won’t show up in the disk utility.

So what’s the problem with Western Digital HDD’s ? This isn’t the first time I saw an WD disk stop working immediatly without any warnings. If it would be the hard drive of my macbook then ok, this one I carry around a lot. But my iMac is standing at the same position for over 1 1/2 years and wasn’t moved a single time.

this is a dark secret to me ?

what I’ve learned from this ……

BACKUP, daily BACKUP and another daily BACKUP

bash screen auto reattach

automatically search for an attached screen session at login and reattach

cb0@home:~/$cat >> ~/.bashrc << EOF
if [ \$SSH_TTY ] && [ ! \$WINDOW ]; then #comment out for local usage
  SCREENLIST=\`screen -ls | grep 'Att'\`
  if (( ! \$? )); then
    echo -e "Screen running and attached:\n \${SCREENLIST}"
  else
    screen -U -R
  fi
fi #comment out for local usage
EOF

[:edit:]

The script above only works when you connect through ssh. If you login from a real terminal $SSH_TTY and $WINDOW won’t be set.
Comment out lines marked for local usage if like screen as much as i do.