Unix Power ToolsUnix Power ToolsSearch this book

1.15. Your Home Directory

Microsoft Windows and the Mac OS have hierarchical filesystems (Section 1.14), much like those in Unix and other large systems. But there is an important difference. On many Windows and Mac systems, you start right at the "root" of the filesystem tree. In effect, you start with a blank slate and create subdirectories to organize your files.

A Unix system comes with an enormous filesystem tree already developed. When you log in, you start somewhere down in that tree, in a directory created for you by the system administrator (who may even be yourself, if you are administering your own system).

This directory -- the one place in the filesystem that is your very own, to store your files (especially the shell setup files (Section 3.3) and rc files (Section 3.20) that you use to customize the rest of your environment) -- is called your home directory.

Home directories were originally stored in a directory called /usr (and still are on some systems), but are now often stored in other directories, such as /home. Within the Linux Filesystem Hierarchy Standard (FHS), the home directory is always at /home, as configuration files are always in /etc and so on.

To change your current directory (Section 1.16) to your home, type cd with no pathname; the shell will assume you mean your home directory.

Within the Mac OS X environment, home is in the /Users/username directory by default.

-- TOR



Library Navigation Links

Copyright © 2003 O'Reilly & Associates. All rights reserved.