PageRenderTime 7ms CodeModel.GetById 2ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/contrib/dialog/samples/report-string

https://bitbucket.org/freebsd/freebsd-head/
#! | 23 lines | 22 code | 1 blank | 0 comment | 0 complexity | ae7cde14e9da94b536f8fd7f981494a6 MD5 | raw file
 1# $Id: report-string,v 1.2 2010/01/13 10:00:11 tom Exp $
 2# Report result passed in a string $RESULT
 3# vile:shmode
 4
 5case $retval in
 6  $DIALOG_OK)
 7    echo "Result is $RESULT";;
 8  $DIALOG_CANCEL)
 9    echo "Cancel pressed.";;
10  $DIALOG_HELP)
11    echo "Help pressed ($RESULT).";;
12  $DIALOG_EXTRA)
13    echo "Extra button pressed.";;
14  $DIALOG_ITEM_HELP)
15    echo "Item-help button pressed.";;
16  $DIALOG_ESC)
17    if test -n "$RESULT" ; then
18      echo "$RESULT"
19    else
20      echo "ESC pressed."
21    fi
22    ;;
23esac