Полезная информация

Next Up Previous Contents Index
Finding Yourself With <tt>pwd</tt>

2.1 Finding Yourself With pwd

Sooner or later (probably sooner), when you start looking through directories, you're bound to ask, ``Where the heck am I?'' And you won't be speaking philosophically.

DOS can answer that question just by showing you at the prompt like:

C:GAMES\Quake\ID1>

Your Linux system, by default, just shows your current directory.

Figure 20: The command pwd shows you where you are

Try this: open an xterm window. You'll see something like:

[billy@localhost billy]

Now type:

pwd

What do you see? Something like

/home/billy

The command pwd stands for print working directory. When you typed pwd, you were asking your Linux system, ``where am I?'' Your system responded by ``printing'' the directory you're in to the monitor (as shown in Figure 20).

Seems easy, right? It ought to be; you'll be using pwd plenty as you look around. (Even Linux gurus depend on this little command.)


Next Up Previous Contents Index