Misc Page at IITD

C / C++ in existing Eclipse IDE

Date : Monday, 17th September, 2012

I always love when it comes to Eclipse... Started with Java, I added (from here) support for python (PyDev) in Eclipse. But browsing on google for adding support for C / C++ seemed to suggest downloading of new IDE ( even though it is some version of eclipse, it is not the same installation which we use for Java ).

There is a way to add support for C/C++ within existing installation of Eclipse. You can follow following steps :

    1. Open Eclipse, Go to Help > Install New Software

    2. Click on "Available Software Sites"

    3. Select http://download.eclipse.org/tools/cdt/releases/indigo. NOTE: 'indigo' is my version, for you, this may be different. Hit Ok.

    4. In 'Work with' drop down menu, select http://download.eclipse.org/tools/cdt/releases/indigo

    5. Select whole CDT Main Features

    6. From CDT Optional Features, select both : C/C++ GNU Toolchain {Build|Debug} Support.

    7. Hit Next.

    8. Some procedure from this point onwards will be updated.

CSCOPE Usage

Date : Thursday, 9th August, 2012

I prefer cscope -CqRv for examining a large project of C files like GCC or linux kernels.

CTAGS Usage

Date : Tuesday, 7th January, 2014

As I use vim editor instead of emacs, I use ctags instead of etags to create tag files for vim. I use "Exuberant Ctags" instead of its GNU version because I found applying ctags recursively for hierarchy of directoris easy in Exuberant Ctags than GNU version. I prefer the command ctags -R *.

UPDATE: Recently I bumped into a problem where a tags file was getting generated properly but vim was not able to find tags when I tried to find a tag from a subdirectory. Basically a fix is to instruct vim to keep looking for tags file up a directory at a time till it reaches root. I found this stackoverflow page useful. I added this line : set tags=tags;~,TAGS;~ to this file : ~/.vimrc . And then ran catgs -R *.

Metro Map - Source Wikipedia

Date : Friday, 30th November, 2012

Link to Delhi Metro Map.

Places to Visit in Delhi - List is not exhaustive and is / will always be under construction!

Date : Friday, 30th November, 2012. Last updated : June 16, 2013.

State Houses - Offer excellent regional food menus.

Date : Friday, 30th November, 2012

This blog seemed good and informative to me.

Official page lists all the Resident Commissioners/ Representatives of State Govt. and Union Territories's.

Avoid accidentally deleting everything by wrong usage of linux command rm -rf *.

Date : Tuesday, 5th February, 2013

Create a file with a name "-i" in any directory whose contents you want to prevent from accendental deletion.( for ex. $(HOME)) Create it using "touch -- -i" or "touch ./-i".

Whenever command "rm -rf *" gets executed in the directory, the -i file will be interpreted by rm command as one of the switch! and it will ask :

rm: remove directory `a'? n

rm: remove directory `b'? n

rm: remove directory `c'? n

rm: remove directory `d'? n

Now if you DO WANT to delete all contents in this directory, first remove '-i' file : "rm ./-i" and then, ususal "rm -rf *".

Use cscope utility with *.java files

Date : Tuesday, 12th February, 2013

Found this info from this usefule blog : Link.

In the project root directory, do : find ./ -iname *.java > cscope.files

Then you can use cscope in usual way ( for e.g. cscope -CqRv).

Change or Reset windows password from Ubuntu Live CD

Date : Sunday, 1st September, 2013

This website gives a very detailed procedure : Link. I have not checked if this works!

Want to know which flight is crossing you at this moment?

Date : Saturday, 28th September, 2013

Check out LIVE status of flights all over the world here.