Tuesday, June 13, 2006

You can listen to any PDF instead of reading with
Adobe Reader 7 .0 Or 6.0, and the short cut is:

Ctrl+shift+b - to hear the entire Document
Ctrl+shift+v - to hear the page
Ctrl+shift+c - to pause and resume
Ctrl+shift+e - to stop

Open any PDF File and test....

Friday, January 06, 2006

If you ever need to recompile your kernel!!!

do the following steps!
1. go to directory where linux source is kept
2. run make xconfig (you can also do menuconfig), and choose all that you need for the kernel
3. make clean
4. make depend
5. make bzImage (this builds the image)
6. make modules (this builds the kernel modules)
7. make modules_install(god knows)
8. cp arch/i386/boot/bzImage /boot/vmlinuz-2.2.24-new
9. cp System.map /boot/System.map-2.2.24-new
10. edit /etc/lilo.conf
add following lines
image=/boot/vmlinuz-2.2.24-new
label=linux-new
11. lilo -v

Monday, November 21, 2005

Useful gvim tips

set incsearch
set ic
set ruler
set hls
set smartindent
sy on
set tags=
set cindent
set sw=4
set ts=4
set expandtab
set softtabstop=4
set guifont=-BIZNET-FotinosTypewriter-Medium-R-Normal-Sans-12-120-75-75-M-70-ISO8859-2
highlight Normal guibg=grey

Useful X specific commands

xhosts + (disables access controls)
xset -d (disables beeps)

Thursday, September 01, 2005

Dont know XML???

http://www.vivtek.com/xml.html
http://www.xml.com/

generate XML parser code???
link is here!!!
http://www.rpbourret.com/xml/XMLDataBinding.htm
http://sourceforge.net/projects/xmel/

here is nice faq's about XML namespaces and its myths!
http://www.rpbourret.com/xml/NamespacesFAQ.htm
http://www.rpbourret.com/xml/NamespaceMyths.htm#myth4

Tuesday, August 30, 2005

Some APIs for bench marking performance

getrusage()
gethrtime()
gethrvtime()

The above api's might not be available in all the platforms consistently.

Wednesday, August 17, 2005

Regular expression greps (egrep)
use egrep instead of grep

for ex:
egrep "yes|no"

will grep for occurence of lines containing "yes" or "no" in the given file.

Useful GDB tutorial on process memory map etc..

memory layout and stack

definitely useful link to be read before you attend any interview or conduct an interview, esp folks who forget basics very often.

Tuesday, August 02, 2005

Useful GDB commands

How to set display length of character buffer?
You should have noticed that whenever you try printing a big buffer, GDB will print only first few characters. This happens due to default GDB configuration, where "print elements" might have been set to 200. To change the print limit to higher value, do the following on GDB prompt.

set print elements 2000

You can also make use of show command in GDB to get all the values set for various configuration variables as follows:

show print

How to print stack information?
here is the link

example gdb commands:
info args
info locals

I shall add more GDB know-how's as I learn them

Shell commands
How to extract unique line entries from a file?

cat | sort -u
This command is particularly useful where you have lots of repeating information such as IDs, URLs which appear as separate lines.

Pattern search on gvim not matching part of string?
/[^]
ex
/leaked [^0]
The above vim search will highlight the non-Zero leak occurances.

How to list contents of tar archive?
tar -tvf