added a new function to display the help usage

This commit is contained in:
aminnairi
2024-01-04 12:38:56 +01:00
parent ff865f7484
commit bf27b28684
+9
View File
@@ -1,5 +1,14 @@
#!/bin/env bash
function display_help() {
first_playbook_found="$(find ansible -maxdepth 1 -type f -name '*.yml' | head -1 )"
echo "Example usage for interactive mode:"
echo " bash $0"
echo "Example usage for non-interactive mode:"
echo " bash $0 $first_playbook_found"
}
ERROR_BECAUSE_ROOT=1
ERROR_BECAUSE_NOT_ARCH_LINUX=2
ERROR_BECAUSE_TOO_MUCH_ARGUMENTS_PROVDED=3