

This is the prompt where you can enter commands in order to have them executed. No error message is displayed.Īs soon as both of these files have been read, the shell displays a prompt −

If it exists, the shell reads it otherwise, the shell skips it. Your home directory is the directory that you start out in after you log in. The shell checks to see whether the file. The shell checks to see whether the file /etc/profile exists. This is usually a two-step process that involves the shell reading the following files − When you log in to the system, the shell undergoes a phase called initialization to set up the environment. These variables retain their values until we come out of the shell. Note that the environment variables are set without using the $ sign but while accessing them we use the $ sign as prefix.

The value assigned could be a number, text, filename, device, or any other type of data.įor example, first we set a variable TEST and then we access its value using the echo command − Some are set by the system, others by you, yet others by the shell, or any program that loads another program.Ī variable is a character string to which we assign a value. An important Unix concept is the environment, which is defined by environment variables. In this chapter, we will discuss in detail about the Unix environment.
