lunatechian (lunatech-ian)

one relating to, belonging to, or resembling lunatech

php manual on your hdd

One of the strong points of PHP is its well annotated online manual, which is peppered with useful code snippets and hints. How many times have you pointed your browser to php.net/manual/ to look up that at-the-tip-of-your-mouth function's argument list ? If you or your company use the manual frequently, it might be a good idea to mirror the manual in your internal network. I have mirrored the manual in my office, and the two benefits that I see are

  • Faster manual lookup - Living in a bandwidth starved country(India), this is a major win for us.
  • A peek at well written code, again a major win if you are always looking for new and nifty way for doing things

The process of how to go about mirroring the manual is surprisingly well documented at Mirroring The PHP Website. As suggested by the documentation, You may want to exclude out certain non essential things ,like the manual in different languages. I also excluded the tar.gz and the zip files in the extra directory.

After downloading the manual pages, I created the virtual host (a simple copy-paste with some minor modifications) for the manual and that was it. To keep the manual uptodate I run the rsync command once a week.

For the record, my rsync command is rsync -avzC --timeout=600 --delete --delete-after --include='manual/en/' --include='manual/en/**' --exclude='manual/**' --exclude='distributions/manual/**' --exclude='distributions/*.exe' --exclude='extra/*.zip' --exclude='extra/*.tar*' --exclude='distributions/*' rsync.php.net::phpweb ./ Of course, you will need to change this to suit your needs.

Defined tags for this entry:

Against signing online petitions

I must write this before I am drowned in "armchair activism".

Armchair Activism refers to efforts to influence socio-political change through the ineffective use of e-mail and Web sites, ignoring safer, more effective means of advocacy. Armchair Activism comes in two basic flavors: the e-petition and the boycott chain. Both are typically poorly designed, misguided and pitifully ineffective.
(Taken from Break the chain)

A few days back I received an email asking me to sign an online petition protesting against the move to have reservation for SC/ST in private sector companies. Of course, I did not sign the petition. Anyone can create a online petition and any one can sign it. If you really want to support a cause, then break into your piggy bank. Put your money where your mouth is. Seriously, if you care about something, is creating a petition on PetitionOnline.com the best you can do ? If you want to see some change in the way the system works, you have to exert yourself. We live in a real world, where decisions are not changed because some minister receives an email with hundreds of signatures (none of which can be verified). Emails can be deleted and forgotten about. However, it is hard to delete the articles in the newspapers, it is harder to ignore the criticisms on the TV and it is even harder to ignore people protesting on the streets or sitting on a hunger strike or a Public Interest Litigation filed against a government decision.

Defined tags for this entry: ,

copy paste job

Yesterday while chatting on IRC, one of the participants pointed to the Reliance's "Acceptable user Policy (AUP)" (sic!). You can find a copy here. Interestingly, the Reliance's AUP is a copy and paste job of UKFast's AUP. Of course, not the whole thing is a ditto copy, let it be known that Reliance is not an amateur. It has added one line in the end listing the ports it has blocked and replaced all instances of UKFast with Reliance.

This reminds me of an argument I had with one of my friends a few months back. We were going through some flyers that one of our clients had sent us (we were to create some web content based on the flyers). I pointed out a few grammatical errors in the flyer but my friend said ,"The people who made these are professionals, getting paid more than you to write these. Don't you think you are the one who is wrong ? " (of course, this is slightly paraphrased). This just goes to prove my point, "Incompetence and laziness is not a forte of only small companies".

Defined tags for this entry:

an argument for atheism

When I had gone back to my village, I had an argument with my family over existence of god. A line of reasoning that they (more precisely, my mother) took was

  1. there are gazillions of people who have faith in god,
  2. Faith is equal to science
  3. there is a scientific reason for believing in god
Though I seldom tried to breach their faith, this time I took a hard stance and tried to show them the error in their logic.

A central concept in the philosophy of science is empiricism, or dependence on evidence. Any scientific experiment can be replicated by anyone who cares to undertake it, and any theory is based upon sound experimentation and/or observation. The same cannot be said about religion and god. Are their experiments to prove the existence of god ? I agree that there are no experiments to disprove his existence too, but that does not automatically proves god's existence. Another line of argument they take is "Appeal to Authority" i.e. how Newton, C.V.Raman and some other scientists believed in god. With all due respect to these great names, I do not think they have been able give experiments to prove the existence of god, and hence taking their words at the face value is not a scientific process. At this point they stopped arguing with me any further :-)
Defined tags for this entry:

Why am I going to my job today

I was reading an article, Do It Now, which talks about time management. One of the first points the article says about time management is - Clarity is key. The first step is to know exactly what you want. I thought to myself, "Why am I going to my job today ?". I tried to think of a good reason what my current job will let me accomplish in my life and I have not been able to come up with a concrete answer. I will think about this question some more for a few more days and see if this job is aligned with where I want to go.

Defined tags for this entry:

Disney is taking the fight against recording of movies to ridiculous levels. Defamer has an account of what took place during the screening of the movie "The Life Aquatic".

The Disney thought police were out in full force, with their ridiculous mouse-eared 'cast' buttons no less. This is really getting out of hand.
[snip]
Once they take your cell phone and drivers license it's placed into a plastic bag and you are given a ticket to redeem them later (just like in prison!). After this you are then asked to open your bags and raise your arms while a metal detector is run all over your body.
[snip]
After you have run this gauntlet, during the film you are subjected to even more security as annoying red security dots with tracking id's flash on the screen every 15 minutes and scowling uniformed security personal scan the audience like the secret service.

I do not know when these measures will start getting implemented in India. It is quite easy to get "hall prints" of the new movies from any of the local CD shops in Delhi. From anecdotal conversations, I gather that these prints are not made by viewers. There is a collaboration between the CD shop and the guy who does the actual screening of the movie.

It feels good to be living in a free country. Thanks to boing-boing for the link

Defined tags for this entry:

I had gone to visit my village for the ocassion of Chhat. Some of the conveniences that I had started taking for granted were missing. It made me appreciate how easy city life is and how hard a rural life is. However one thing that stood out was the ubiquity of the mobile phones.
Defined tags for this entry: