1. Create a file
touch abc.sh (Linux does not recognize the suffix of the file, and the .sh suffix is added for the convenience of classification, so that the user can know that it is a shell script at a glance)
2. Edit the file content and write the code
#!/bin/sh
echo "hello world!"
(The first line is required, to formulate the place where SHELL is executed,
The beginning of the second line is where you write your own code.)
3. Change the file permissions to make the file an executable file
chmod + x abc.sh
4. Execute the file
./abc.sh