| 1234567891011121314151617181920212223242526272829 |
- #!/bin/bash
- # Licence : GPL v3
- # Author: Laurent HUBERT
- #
- # Example file for first-boot-script
- # Copy this file to a new file and add permission execution to the new file
- # Example:
- # # cp skeleton 02-myscript
- # # chmod +x 02-myscript
- #
- # Example Section : Displaying a banner
- cat <<EOF
- ##############################
- # My Banner #
- ##############################
- EOF
- # Example Section : asking user to enter a value
- read -p "Please enter a value: " answer
- # Example Section: use the value only if not empty
- if [ -n "$answer" ]
- then
- echo Using $answer as user data
- # Do something here
- exit 0
- else
- # Exit with non zero status
- exit 1
- fi
|