Horje
bash Creating help function Code Example
bash Creating help function
#!/bin/bash
############################################################
# Help                                                     #
############################################################
Help()
{
   # Display Help
   echo "Add description of the script functions here."
   echo
   echo "Syntax: scriptTemplate [-g|h|v|V]"
   echo "options:"
   echo "g     Print the GPL license notification."
   echo "h     Print this Help."
   echo "v     Verbose mode."
   echo "V     Print software version and exit."
   echo
}

############################################################
############################################################
# Main program                                             #
############################################################
############################################################
############################################################
# Process the input options. Add options as needed.        #
############################################################
# Get the options
while getopts ":h" option; do
   case $option in
      h) # display Help
         Help
         exit;;
     \?) # Invalid option
         echo "Error: Invalid option"
         exit;;
   esac
done


echo "hello world!"




Shell

Related
how to clone a repo with a different name Code Example how to clone a repo with a different name Code Example
samtools extract sequence from bam file Code Example samtools extract sequence from bam file Code Example
unknown type name 'CDVUIWebViewDelegate'     CDVUIWebViewDelegate* _webViewDelegate; Code Example unknown type name 'CDVUIWebViewDelegate' CDVUIWebViewDelegate* _webViewDelegate; Code Example
how to find current active yarn resource manager Code Example how to find current active yarn resource manager Code Example
protoc command not found linux docker Code Example protoc command not found linux docker Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
14