VisionOS's Weblog

December 26, 2009

commandlinefu

Filed under: uncategorized — visionos @ 8:55 pm

http://www.commandlinefu.com/

a website dedicated to handy commands

November 15, 2009

alma mater

Filed under: uncategorized — visionos @ 5:02 am

母校

November 2, 2009

Ten Commands Every Linux Developer Should Know

Filed under: uncategorized — visionos @ 4:07 am

Worth take a look and find tools useful to you.

http://www.linuxjournal.com/article/7330

fuser: a long desired tool

Filed under: uncategorized — visionos @ 4:05 am

Finally I found the right tool for the task — tell which process have opened a given file.
===
The name is a mnemonic for file user and tells what processes have opened a given file. It also can send a signal to all those processes for you. Suppose you want to delete a file but can’t because some program has it open and won’t close it. Instead of rebooting, type fuser -k myfile. This sends a SIGTERM to every process that has myfile opened.

Perhaps you need to kill a process that forked itself all over the place, intentionally or otherwise. An unenlightened programmer might type something like ps | grep myprogram. This inevitably would be followed by several cut-and-paste operations with the mouse. An easier way is to type fuser -k ./myprogram, where myprogram is the pathname of the executable. fuser typically is located in /sbin, which generally is reserved for system administrative tools. You can add /usr/sbin and /sbin to the end of your $PATH.

Love and UNIX: An Undying Affection (ZZ)

Filed under: uncategorized — visionos @ 4:02 am

An operating system, like almost anything, is a reflection of the values, personality, and ultimately, the psyche of the designer. And its followers usually agree with these perspectives.

(copied from http://broadcast.oreilly.com/2009/02/love-and-unix-an-undying-affec.html)

VIM :g

Filed under: uncategorized — visionos @ 3:53 am

Do something on lines that mach a search pattern (this is what I always forget because I don’t use it that often):
:g/search pattern/command

Delete empty lines using the above:
:g/^$/d

Delete lines starting with #
:g/^#/d

Two commands in VIM

Filed under: uncategorized — visionos @ 3:44 am

:pwd
:cd xxx

November 1, 2009

valgrind

Filed under: uncategorized — visionos @ 7:11 pm

I used to think valgrind is complex to use. Actually it turned out it is very simple and powerful tools to catch common memory leak/access problems. Every one who program should use this tool, it will save you tons of time.

October 26, 2009

Nvidia naming

Filed under: uncategorized — visionos @ 3:34 am

After Tesla and Fermi, I realized that NVidia has been naming their products based on famous physicists’ names.

Similarly open source developers like to name their product/releases based on animals, lik Ubuntu, etc.

Celebrity and Gossip

Filed under: uncategorized — visionos @ 3:30 am

娱乐八卦

Next Page »

Blog at WordPress.com.