You can also use Ctrl +R to search (backward) through the history.
You can capture the output from a c ommand in a n e nv ironment variable using back-ticks:
$ TIME =`date`
$ echo $TIME
Sun Mar 31 21:56:03 IST 2013
As on most UNIX-like systems, each user on OpenSolaris has a home directory. Your home
directory path is stored in the HOME environment variable. You can also use the tilde character
(~) to navigate to your home directory or to another user’s home directory. The tilde alone
implies the current user’s home directory. The following code shows how to navigate to home
directories:
$ cd ~
$ pwd
/export/home/sourav
$ cd ~sougata
$ pwd
/export/home/sougata
This example also demonstrates that the pwd command shows your current working directory.
No comments:
Post a Comment