Archive

You are currently browsing the Tuxyves ;-) blog archives for the day Monday, March 8th, 2010.

Mar

8

Search under Linux

By admin

- To search something in all of the disk :
locate "file or folder"
- To search something with path (word in all files) :
find /path/to/dir/ | xargs grep --color "1234" -n
find ../../ -name "*.c" | xargs grep --color "long"
or
grep -r "1234" *

NB: for find : “-L” to follow the symbolic link; for grep “-r” <= recursive; "-n" <= display line number

- To search where is installed an executable on disk :
which “software_name”
$> which nautilus
/usr/bin/nautilus

Mar

8

Linux symbolic link

By admin

To create a symbolic link in Unix or Linux, at the shell prompt, enter the following command:
ln -s {$target-filename} {$symbolic-filename}

Alias => to call “vim” with “vi” shell command :
alias vi=vim