Thursday, November 09, 2006

Firefox trusts Google in Linux a lot?????

Most of you might have known the feature provided by Google. Using your id you can save your search and use other services offered by Google. I'll do it regularly. I am using a dual boot (FC5, XP) machine. I was logged into my Google account using Firefox on my linux. Without signing out, I closed my browser and rebooted to Windows. When I logged in to linux again and opened Firefox, I saw that im logged in to my Google account. I could not believe it. I tried it multiple times. It was happening repeatedly. But this does not happen in Windows.

Seems like the session information is serialized by firefox in linux and it is used subsequently. This happens only with Google and not with any other sites like Yahoo, Hotmail....

Can anybody explain why??

Wednesday, November 08, 2006

Export Variables from Shell scripts

This time, I got a script that sets some environment variables. They had suggested to run as . script . I noticed it, but I didn't cared about that and ran it in the traditional way as ./script . When I echoed the variable, it was not displayed. Then I tried as they have mentioned (Obviously after meddling with the scripts :)). Wow, I got the values. But how????? I googled and then found out that

"When we run a script using ./script it creates a separate shell and then run it. So, since the variable is exported in that shell, it is not available to the parent shell after completion.

When we run a script using . script it runs the script in the same shell which makes the variables available even after the completion of the script."


In Tamil, we have a saying "Katradhu kai mann alavu. Kallaadhadhu ulahalavu". Meaning, Whatever you know is the amount of sand you can have in your hand. Whatever you dont know is as huge as the world. :)