Use the 'chmod' command to change permissions on any file. Note: you have to be the owner (or the superuser) to do this.
Make sure it is readable and executable (permissions). Then, just type in the name of the shell file to execute it.
Actually, just about anything you want to do. Depends on the job function requirements.
Essentially, a command in Unix is a program that you execute for a certain purpose. It could be anything, from a shell script, to copying or deleting files, etc.
# SS29 # Script to delete all lines containing the word 'unix' from files supplied as arguments # Usage: SS29 file1 file2 file3 ... if [$# -lt 2] then echo Insufficient arguments exit fi for file do grep -v unix $file>/temp/$file cp /temp/$file $file done
Unix is inherently portable; this means that a program, script, or process may be moved from Unix system to Unix system with little effort or change (hence - portable).
Your login shell can be changed by using the chsh or ypchsh command.
The 'exit' command allows you to stop a running shell script at any point and to return a "status" value back to whomever called the shell script. This is a very common practice with shell scripts; sometimes you want to stop the script before it gets to the end of the shell script (for various logic reasons). The 'exit' command also allows you to give a status that any other calling process can use to determine if the shell script ended successfully or not.
There are no actual "hidden" files in Unix. The only way to hide the existence of a file is to place it in a folder that no one has read permissions for.
For windows, you might use .cmd, .bat as common file extensions. Unix doesn't use file extensions as associations, so no file extension needs to be used in the Unix environment. A shell script in Unix is simply a text file with any name that is readable and executable. However, file extensions are typically used in Unix as a documentation aid that states that the file is a shell script. Common extensions are .sh, .csh, .ksh, .tcsh, .zsh, etc.
The local user files that are read are the .login and the .cshrc files
The trap command is used in a shell script to intercept certain types of software signals; usually it is used to do a "graceful" cleanup when the shell program is interrupted.
There is no "default" Unix shell. Different Unix vendors shipped different shells.