Photoshop web design - Chapter 2 . Running Commands from the Shell

Chapter 2 . Running Commands from the Shell 57 Variable Description PATH The colon-separated list of directories used to find commands that you type. The default value for regular users is /bin:/usr/ bin:/usr/local/bin:/usr/bin/X11:/usr/X11R6/bin:~/ bin. You need to type the full path or a relative path to a command you want to run that is not in your PATH. For the root user, the value also includes /sbin, /usr/sbin, and /usr/local/sbin. PPID The process ID of the command that started the current shell (for example, its parent process). PROMPT_COMMAND Can be set to a command name that is run each time before your shell prompt is displayed. Setting PROMPT_COMMAND=date lists the current date/time before the prompt appears. PS1 Sets the value of your shell prompt. There are many items that you can read into your prompt (date, time, username, host name, and so on). Sometimes a command requires additional prompts, which you can set with the variables PS2, PS3, and so on. PWD This is the directory that is assigned as your current directory. This value changes each time you change directories using the cd command. RANDOM Accessing this variable causes a random number to be generated. The number is between 0 and 99999. SECONDS The number of seconds since the time the shell was started. SHLVL The number of shell levels associated with the current shell session. When you log in to the shell, the SHLVL is 1. Each time you start a new bash command (by, for example, using su to become a new user, or by simply typing bash), this number is incremented. TMOUT Can be set to a number representing the number of seconds the shell can be idle without receiving input. After the number of seconds is reached, the shell exits. This is a security feature that makes it less likely for unattended shells to be accessed by unauthorized people. (This must be set in the login shell for it to actually cause the shell to log out the user.) UID The user ID number assigned to your username. The user ID number is stored in the /etc/password file. Set Your Own Environment Variables Environment variables can provide a handy way to store bits of information that you use often from the shell. You can create any variables that you want (avoiding those that are already in use) so that you can read in the values of those variables as you use the shell. (The bash man page lists variables already in use.)
Note: If you are looking for high quality webhost to host and run your jsp application check Vision jsp web hosting services

Leave a Reply