Tuesday, September 18, 2007

Firefox QuickFind using /

Tabbed browsing was one of the main features that got me attracted to Firefox. Earlier I used Crazy Browser that works on top of IE for tabbed browsing. Soon enough IE7 brought the tabbed browsing feature.
Another feature that I really like about Firefox is the Find(Ctlr + f) feature that searches as you type the characters. One feature that I didn't know until lately was the QuickFind feature wherein you use the slash (/).Vim users will find this particularly useful! But the annoying part is that I tend to use 'n' instead of F3 to Find-next.
Firefox should support the 'n' for QuickFind just like vim and may be have an escape sequence for the conventional n !

Sunday, September 9, 2007

Synergy: Share your mouse and keyboard across different operating systems

Synergy lets you share mouse and keyboard across multiple monitors even with different operating systems!

For step-by-step instructions follow this link http://www.mattcutts.com/blog/how-to-configure-synergy-in-six-steps
This site specifically mentions Ubuntu distro but you can download the source from here and install using the typical linux commands
./configure
make
sudo make install

The above page uses Linux as server. Initially I tried setting up Windows as a server using this link
But the GUI wasn't intuitive and faced some networking issues so switched to Linux instead.

In the synergy.conf file under the aliases section you can specify IP address of the screen. Each screen can have multiple aliases; 1 per line (no colon).
The synergys (server daemon) uses gethostname() so if you've specified screen name that is different than the hostname then use -n server_screen_name while starting the synergys.

For more troubleshooting information refer here

If you are using KVM then make sure that the respective monitors are directly connected to the VGA port and not to the KVM switch!!

Work seamlessly. Enjoy!

Wednesday, September 5, 2007

cscope + vim


Using cscope with vim will allow you to browse code seamlessly. Refer to the following link for setting up the mapping between cscope and vim http://cscope.sourceforge.net/cscope_vim_tutorial.html

Download the mapping file here http://cscope.sourceforge.net/cscope_maps.vim

Go to the top-level source directory and type cscope -R

I faced "duplicate database found" error and so had to comment out following lines from cscope_maps.vim

" add any cscope database in current directory
if filereadable("cscope.out")
cs add cscope.out
" else add the database pointed to by environment variable
elseif $CSCOPE_DB != ""
cs add $CSCOPE_DB
endif

Also remember to open the source file from the same source level directory where you typed cscope -R else mapping won't work.

For example:
Consider directory /src/linux/foo/bar
If you created cross-reference DB in /src and want to open file a.c in /src/linux/foo/bar then cd into /src and then open file using
vim linux/foo/bar/a.c