handle specific help anywhere

master
George Danchev 11 years ago
parent daf7a078bd
commit ada1b1114a
  1. 10
      releng/auto_cxx
  2. 9
      releng/auto_isocontent
  3. 9
      releng/auto_isojigdo
  4. 9
      releng/auto_printsize
  5. 4
      releng/inc/releng_getopts.inc
  6. 4
      releng/manual_devices
  7. 15
      releng/template_new

@ -12,8 +12,16 @@ not_in_releng_exit() {
. inc/releng_getopts.inc || not_in_releng_exit
# xorriso binary is not needed for that particular test
#print_specific_help() {
# # NONE YET
#}
if test "$SPECIFIC_HELP" = 1; then
# print_specific_help
exit 0
fi
# xorriso binary is not needed for that particular test
SAMPLE_CODE_DIR=codesamples
CC=g++

@ -14,6 +14,15 @@ not_in_releng_exit() {
. inc/releng_getopts.inc || not_in_releng_exit
#print_specific_help() {
# # NONE YET
#}
if test "$SPECIFIC_HELP" = 1; then
# print_specific_help
exit 0
fi
if [ ! -x $RELENG_XORRISO ]; then
print_help
printf "\n${SELF}: -x absolute or relative path to binary to be run.\n\n"

@ -13,6 +13,15 @@ not_in_releng_exit() {
. inc/releng_getopts.inc || not_in_releng_exit
#print_specific_help() {
# # NONE YET
#}
if test "$SPECIFIC_HELP" = 1; then
# print_specific_help
exit 0
fi
if [ ! -x $RELENG_XORRISO ]; then
print_help
printf "\n${SELF}: -x absolute or relative path to binary to be run.\n\n"

@ -13,6 +13,15 @@ not_in_releng_exit() {
# Include common bits
. inc/releng_getopts.inc || not_in_releng_exit
#print_specific_help() {
# # NONE YET
#}
if test "$SPECIFIC_HELP" = 1; then
# print_specific_help
exit 0
fi
# Each test should decide whether or not it needs
# a xorriso binary to test, since some do compilations only.
if [ ! -x $RELENG_XORRISO ]; then

@ -6,7 +6,7 @@ SELF=$(basename $0)
RELENG_XORRISO=0
SIMULATE_FAILURE=0
CLEANUP=1
RELENG_PRINTED_HELP=0
SPECIFIC_HELP=0
START_DIR_DONT_CHANGE=`pwd`
GEN_DATA_DIR=releng_generated_data/${SELF}
@ -144,7 +144,7 @@ do
elif test x"$i" = x"-h"
then
print_help
RELENG_PRINTED_HELP=1
SPECIFIC_HELP=1
elif test x"$i" = x"--"
then
# Begin of private arguments for caller

@ -8,7 +8,7 @@
print_specific_help() {
# Print own help text
echo "Test specific options:"
echo "Specific options:"
echo " --dev path Suppress dialog and use path as drive address."
echo "This test insists in getting a path to xorriso by option -x."
echo
@ -20,7 +20,7 @@ if test -e "$getopts_inc"
then
. "$getopts_inc"
if test "$RELENG_PRINTED_HELP" = 1
if test "$SPECIFIC_HELP" = 1
then
print_specific_help
exit 0

@ -3,17 +3,30 @@
# Copyright 2011 George Danchev <danchev@spnet.net>
# Licensed under GNU GPL version 2 or later
set -e
not_in_releng_exit() {
printf "\nPlease execute the tests from releng directory.\n\n"
exit 1
}
set -e
print_specific_help() {
# Print own help text
echo "Specific options:"
echo " NONE YET"
echo
}
# Include common bits
. inc/releng_getopts.inc || not_in_releng_exit
#
printf "\n$0: FAIL: === TEPLATE === RENAME ME TO [auto|manual]_<title>\n"
if test "$SPECIFIC_HELP" = 1; then
print_specific_help
exit 0
fi
# Each test should decide whether or not it needs
# a xorriso binary to test, since some do compilations only.

Loading…
Cancel
Save