One hand walking

It seems that Maxim’s walking skills are improving. He tried to walk holding with only one hand today. He succeeded, although it got him by surprise. He was very excited. Tried again – few steps again. We tried it few more times just to give him more confidence and seemed to like it.

I guess we are approaching real walking at full speeds.

I am slightly afraid for his health as that will probably give an overflow of joy…

Lowercasing filenames from the Linux command line

I don’t remember if I posted this little snippet of shell code, so I’ll risk it for the dup.

If you got yourself a messy directory with files – say, all filenames have a mixed case – you can put order in it pretty easy. The example below lowercases filenames of all Jpeg files (JPG and JPEG extensions) in the current directory.

for FILE in *.JP*G
do
  mv "$FILE" `echo "$FILE" | tr A-Z a-z`
done

The algorithm is very simple. For each file in the current directory that has an extension of JPEG or JPG (actually with any symbol between JP and G) execute a mv command. mv requires two arguments – the source filename and the destination. For the source argument we provide it with the name of the currently processed file. The destination filename we find out by filtering the name of the currently processed file through the tr A-Z a-z command.

What does the tr A-Z a-z command do? It simply substitutes latters in one range from appropriate letters in another range. The first range in this example includes all uppercase letters (A-Z), while the second range includes all lowercase letters (a-z).

That’s all folks…

New card reader

Sometimes I feel really stupid. Especially when I realize that I couldn’t properly diagnose the problem. I thought that my microdrive was dying, when in fact it was my card reader. Today I realized the problem in full scope.

Went out and bought myself a new card reader. This time I went for an all in one option. Before I had a need only for CompactFlash compatible media, but now I also have a large Memory Stick Due too.

I got myself a Trust (?) card reader with 16-in-1. Jez! I didn’t even know that there were 16 different card types. My, oh my. Considering that the card reader only has 4 holes to put cards into, I guess all those card types aren’t so different afterall.

11 CYP in ComputerWorld, if you were wondering. Let the file transfers begin!