How to read input from command line from shell script

 How to read input from command line  from shell script

to read dynamically the input argument from command prompt or ssh . in this tutorial we will create a new file

echo "What is your fouravitue number"
echo "Your luck number is  $NUMBER"

after saving the above file , try to execute in the command line


it will ask for input , please enter your desired number,

The same number will be printed on the screen


Popular posts from this blog

Vendor autoload is not found. Please run 'composer install' under application root directory.

Uncaught TypeError: require.config is not a function CSS and Javascript files are not loading after Magento 2 installation

HTTP_RAW_POST_DATA is deprecated from PHP 5.6 onwards and will be removed in PHP 7.0