Home > Article > Operation and Maintenance > What does then mean in linux
What does then mean in linux
Then in English means then, in linux then is a structured command used with if. The most basic if-then structure is if commond then commonds fi, in which if the statement after if is successfully executed, it will jump to the statement after then, otherwise it will not jump.
The most basic if-then structure:
if commond then commonds fi
In shell, it is based on the exit status of the command. If the command is successfully executed and the status is 0, the command after then will be executed. If the command is not successfully executed and the status is a value other than 0
, the command after then will not be executed. The bash shell will move to the next command in the script.
Recommended: Getting started with Linux system
The above is the detailed content of What does then mean in linux. For more information, please follow other related articles on the PHP Chinese website!