/contrib/dialog/samples/yesno-both

https://bitbucket.org/freebsd/freebsd-head/ · Shell · 24 lines · 18 code · 4 blank · 2 comment · 0 complexity · e0a00359ef0439bf255cfb04a77ee78c MD5 · raw file

  1. #!/bin/sh
  2. # $Id: yesno-both,v 1.5 2010/01/13 10:40:39 tom Exp $
  3. . ./setup-vars
  4. $DIALOG --title "YES/NO/MAYBE BOX" \
  5. --clear \
  6. --ok-label "Next" \
  7. --no-label "Cancel" \
  8. --extra-label "Previous" --extra-button \
  9. --help-button "$@" \
  10. --yesno "Hi, this is a yes/no dialog box with its labels changed. \
  11. You can use this to ask \
  12. questions that have an answer of either yes or no (or maybe). \
  13. BTW, do you notice that long lines will be automatically \
  14. wrapped around so that they can fit in the box? You can \
  15. also control line breaking explicitly by inserting \
  16. 'backslash n' at any place you like, but in this case, \
  17. auto wrap around will be disabled and you will have to \
  18. control line breaking yourself." 15 61
  19. retval=$?
  20. . ./report-yesno