Tuesday, September 8, 2009

A Genius Icon

Well, I'm not fan of proprietary stuffs and try to avoid writing about them. Yet, I came across a brilliant work when I was looking at this article about Snow Leopard new extra large icons. Of course it's the never getting old campaign of Apple bashing Windows for its stupid bugs in a genius icon, indicating a Windows host on a network. :)



I guess similar icons could be shipped on stock GNU/Linux distributions to add a little more fun.

Wednesday, September 2, 2009

Highlighting YAML in gedit

I've just written a language spec for YAML so that gedit can highlight it. gedit uses gtksourceview so the highlighting will be available on any application uses the same widget.

Get the latest version from Subversion repository:
svn checkout http://masood.googlecode.com/svn/trunk/yaml-language-spec
or download a tarball from here. Check out the links below if you are also interested in writing a highlighting specification for another language. Links: Language Definition v2.0 Tutorial Language Definition v2.0 Reference

Monday, August 24, 2009

A Perfect Pizza Dough

Baking pizza wasn't really that quick and the end product was usually a horrible flat base with some tasteless stuffs on it. At least that was the case until I found this recipe on taste.com.au originally from Good Taste 1999.

I actually didn't followed the instructions for the sauce and topping but the dough recipe was really good. I modified it a little; if you happen to find any major difference with the original recipe, then it means that I haven't read it properly!

I dissolved 2 tsp of dry yeast and 1 tsp of salt in 1 1/4 cups of warm water. Then I added 2 tbs of olive oil and 3 cups of plain flour . After mix it well and knead for a few minutes, leave it cover for 20 minutes in a warm place. Remember, brush the dough very lightly with oil to prevent it sticking to everything.

I made 2 pizza with this dough and baked it in a fan-forced oven for 20 minutes at 200 °C. Please read the original recipe as it contains a lot more information.



Links:
Basic Pizza Recipe

Wednesday, July 15, 2009

A Cute Drawing

My little sister likes drawing a lot. She often draws sketches of girls with long hairs, dogs and flowers with eyes and mouth. Today, however, she shared with me her vision of universe, a world full of weird looking monsters and candy-shaped planets. So I borrowed it to make my diary cuter!
The work is copyrighted by Shiva Behabadi but if you like to use it, feel free to do so under the terms of Creative Common Attribution-Share Alike 3.0 License

Wednesday, July 1, 2009

Firefox 3.5 on Lenny

Firefox 3.5 is out finally again with no amd64 built ready for download. I didn't want to wait to see if someone is going to package it for Debian Lenny So I decided to compile it from source. Surprisingly, the compilation was smooth and the improved version of my favorite web browser was ready in no time.

I needed these packages to install before compiling Firefox for my Lenny setup:
aptitude install make gcc cvs libgtk2.0-dev libxt-dev libidl-dev \
  libzip-dev libfreetype6-dev libfontconfig-dev pkg-config \
  libdbus-1-dev libasound2-dev libnotify-dev autoconf2.13

After downloading and extracting the source from Mozilla website, I created .mozconfig file in the root of source directory containing these options:
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-@CONFIG_GUESS@
ac_add_options --enable-application=browser
mk_add_options MOZ_CO_PROJECT=browser
ac_add_options --enable-optimize=-O2
ac_add_options --disable-tests
Then the following commands from the root of source tree will do the magic:
export MOZCONFIG=.mozconfig
./configure
make
make -C browser/installer/

Upon the completion, Firefox 3.5 tarball and accompanying language-pack will be placed in dist directory. The tar file can be extracted anywhere and used without installation.

You can find a comprehensive build documentation at Mozilla Developer Center.

Links:
Build Documentation
Firefox 3.5 Source

Friday, June 26, 2009

The Right To Be Uncensored

OK. Maybe it's time to be get a little more serious about this Internet censorship in Australia. I guess a few more protests wouldn't be a bad idea.

Senator Conroy! It's time to wake up. It appears you don't really get it. It is obvious that ISP-level filtering, specially a retarded blacklist method, can never stop people accessing illegal contents. Deny it or not, countries like China and Iran have invested way more than what you have or going to spend on that; still people find a way around it. Either Mr Conroy is getting technical advice from a bunch of retards or he assumes the rest of us to be stupid.

On technical side, keeping a blacklist of a few thousands URLs in a network with more than billions webpages is a joke. On the other hand, packet inspection doesn't seem to be practical with current technology; not only it severely impact the network speed, it'll a hard job to identify what content is actually illegal. Even humans have arguments over it, how would we expect a set of rules and algorithm serve us better?

But, the opposition to the plan is not only a technical but has a far more fundamental ethical aspect. I don't think it'll be long before pro-censorship people begin asking government to filter harmful conversations in instant messaging networks and mobile phones, assuming the plan won't suddenly extend its coverage to political information. I'm sure some can find certain political debates harmful to kids under 15!

Unless we want to end up in a situation like what see in Iran, we shouldn't accept any mandatory censorship of information in a free society. Misuse of such system doesn't happen right from the first day but when influential individuals or group from within and outside country find it necessary. I'm not sure if Senator Conroy or those rallying behind him are willing to take any responsibility for what this nation may suffer as a result of their short-sighted plan.

Wednesday, June 24, 2009

A Yum on Steroid

If you are a Debian user, you would know what a joy is to use apt-get or aptitude specially when those are teamed up with bash-completion scripts.

In contrast, Yum on Fedora has a poor performance and is sometimes annoying. On Fedora 11, bash completion for Yum is virtually impractical to use as it's unbearably slow. It sometimes take up to two minutes for the prompt to return to life.

I don't know much about Yum and my lack of knowledge could be at least partly responsible for the poor performance of this particular setup.

Fortunately, Yum has quite a few plugins which I found some significantly improving its speed. In particular, I have installed rpm-warm-cache, updatesd and refresh-updatesd. It'll surprises you just to see how much faster Yum gets with these plugins and one wonders why these aren't installed by default.

A shot of plugins to keep it going for now:
yum install yum-updatesd yum-plugin-rpm-warm-cache yum-plugin-refresh-updatesd

Saturday, June 20, 2009

You are not alone!

Don't give up! Yesterday, indeed was one of the darkest days of our revolution; the day Khamenei stood on the footstep of the very dictator he fought against before. He promised the same violence and bloodshed that once Pahlavi's regime did to men and women of this land.



What seems inevitable today, I truly hope, be avoided and we don't lose any of our dearest brothers and sisters. But those in Iran who think they are any more powerful than Shah, should know the people who have tasted freedom once will never go back to dictatorship.

I kindly requests from all freedom loving people of this planet not to recognised Iran's government as it is now. Any government that ignores and threatens to brutally suppress a significant (if not majority) portion of its nation is not a legitimate government.

Iran, you are not alone. No matter, what they do to you brave boys and girls, men and women of this great nation, you will not be forgotten. We will be with you till you get what you deserve.

Truecrypt on Fedora 11

Since Truecrypt doesn't officially provide RPM packages for Fedora, you are left with a choice of either compiling your own from the source or using openSUSE RPM (I read somewhere that it would work though I haven't tried it myself).

Well, I chose to compile version 6.1a of Truecrypt on Fedora 10 which worked pretty well. I used these instructions from Penguin Enclave but perhaps for a bug in Truecrypt code, compiling it on Fedora 11 failed.

Fortunately, the version 6.2 has resolved the issue and now it can be easily compiled. Please refer to Penguin Enclave's original post for instructions with the only modification being patching of Common/SecurityToken.cpp:
diff -urN truecrypt-6.2-source.orig/Common/SecurityToken.cpp truecrypt-6.2-source/Common/SecurityToken.cpp
--- truecrypt-6.2-source.orig/Common/SecurityToken.cpp    2009-05-10 17:38:36.000000000 +1000
+++ truecrypt-6.2-source/Common/SecurityToken.cpp    2009-06-20 18:05:33.873119148 +1000 
@@ -657,8 +657,8 @@ 
TC_TOKEN_ERR (CKR_CRYPTOKI_ALREADY_INITIALIZED) 
TC_TOKEN_ERR (CKR_MUTEX_BAD) 
TC_TOKEN_ERR (CKR_MUTEX_NOT_LOCKED) 
-            TC_TOKEN_ERR (CKR_NEW_PIN_MODE) 
-            TC_TOKEN_ERR (CKR_NEXT_OTP) 
+//            TC_TOKEN_ERR (CKR_NEW_PIN_MODE) 
+//            TC_TOKEN_ERR (CKR_NEXT_OTP) 
TC_TOKEN_ERR (CKR_FUNCTION_REJECTED) 

#undef        TC_TOKEN_ERR 

Links:
Truecrypt 6.1 Install Guide for Fedora 10
Bug 496423 related to compilation of Truecrypt on Fedora 11
Truecrypt official website

Tuesday, June 16, 2009

Don't sleep Iran!



Sadly, truth is often bitter. We often don't wanna know about it and hope for the best. I think this is why we vote every now and then despite the usual mismanagements and undelivered promises, hopping tomorrow would be different.

All this time, we could have asked for more but we never asked. Perhaps, we preferred a peaceful life, so peaceful that we felt asleep while some was taking away our very hope. Regardless of election result, ban on protests and strong use of force to suppress the opposition indicates we are almost at the footsteps of a dictatorship.

I'd never recognise such election but like or not, other countries will do just like Russia and China. You've heard it right, all those governments that doubted us every single time and used to call our system a dictatorship, now respect our "democracy" and refrain from involving into our "internal affairs"; one suspects of a secret deal between Ahmadinejad's and other superpowers.

Don't sleep Iran. Not this time. If we don't stand for our freedom, nobody will and we won't get back what we lose today four years later.

Links:
Mousavi1388 twitter
Mousavi1388 Flickr photo gallery
TPM photo gallery 1
TPM photo gallery 2
A very interesting article on current political situation in Iran

Thursday, June 11, 2009

Audio over HDMI

After a bit of discussion on fedora-test-list, reading this bug report and trying out a few parameters from here, I finally got audio over HDMI from my M1330.

I have added following to /etc/modprobe.d/alsa.conf:
options snd_hda_intel model=dell-3stack
I needed pavucontrol to actually select HDMI output profile.

The front audio jacks still don't work but I guess I'll get back to them after mid-year exams.

Wednesday, June 10, 2009

The unfriendly television!

If you happen to have a Samsung Series 6 LCD TV, you probably have already found out that not all the features work out of the box for a Linux user. Fortunately, the fix is easy after a bit of googling.

I was able to get its DLNA working with MediaTomb after adding following lines1 to its configuration file (thanks to crappylogin for sharing the code):
<custom-http-headers ><add header="transferMode.dlna.org: Streaming" /> 
<add header="contentFeatures.dlna.org: DLNA.ORG_OP=01;DLNA.ORG_CI=0; 
DLNA.ORG_FLAGS=01700000000000000000000000000000" /> 
</custom-http-headers> 
and this to mappings tag:
<map from="avi" to="video/mpeg" /> 
Also, X on Fedora 11 doesn't seem to get EDID unless HDMI cable is attached while the system boots. Again, workaround is simply adding correct Modelines using xrandr. Here are Modelines for Samsung LA32B650:
"1920x1080"  148.50  1920 2008 2052 2200  1080 1084 1089 1125 +hsync +vsync 
"1360x768"   85.50  1360 1424 1536 1792  768 771 777 795 +hsync +vsync 
Despite this little annoyance, the TV is a joy to use. It can play contents from a DLNA server as well as USB flash or HDD and has a comprehensive codec support.

I haven't spent much time on it yet but if you are interested, you can download source code of its firmware here.

Links:
http://forums.tversity.com/viewtopic.php?f=2 & amp;t=10992 & amp;st=0 & amp;sk=t & amp;sd=a & amp;start=45

Saturday, February 28, 2009

Education or Censorship?

So what is the obsession with censorship of information? When did it actually achieve its intended goals in the past for any nation? Of course, I meant any achievement other than suppression of free speech and protecting illegal activities of corrupted rulers.

Australia is a great country and we are proud of our diverse and free society but we should not take it for granted. Freedom that we enjoy today has not come at no cost and we should protect it. Our democracy would quickly turn into dictatorship if censorship becomes our quick solution to every problem.

Surely, filtering of Internet in Australia is not only about child pornography and covers whole range of contents labeled 'inappropriate'. Considering our diverse multi-cultural population, such classification will only undermine tolerance and respect in our society and strip a large portion of this nation of their right to information.

In my opinion, censorship in a democratic environment is absurd to say the least. In addition, filtering gives a false sense of security that can lead to more disastrous results. In case of children accessing harmful contents, parents education can be a more effective method as software for control Internet access at home are readily available.

Please join the campaign to end this proposal and stop our government from following the footsteps of others blindly.


No Clean Feed - Stop Internet Censorship in Australia

Thursday, February 26, 2009

TomTom won't be the last one!

Microsoft has sued TomTom for patent infringement. You should have hear it by now and what's better for M$ to have some extra cash and loyalty payment in the middle of a recession. Business as usual with a difference, that is their probable win or settlement can complicate things for FOSS community.

It's unlikely they sue everyone even if patents are to be upheld in court and applicable to other implementations. Others got patents for defend themselves too but that's still not a desired situation to be in for anyone.

OK. I hope you were not looking for any serious opinion or insight because I don't have any. I never liked FAT and I hope FOSS community take a note and don't assume (though I wished) their patents are all as worthless as the UAC one.

So don't format a FAT on that external hard drive if you don't have to attach to a FAT-only sh*t box.