Skip to content

Instantly share code, notes, and snippets.

@azurestone
Created June 28, 2012 08:07
Show Gist options
  • Save azurestone/3009821 to your computer and use it in GitHub Desktop.
Save azurestone/3009821 to your computer and use it in GitHub Desktop.
インプットボックス
#!/bin/sh #
# MacOSX > brew install dialog
# ubuntu > apt-get install dialog
#
tmp=`mktemp /tmp/dialog.XXXXXXXX` || exit 1
dialog --inputbox "May I have your name, please?" 8 70 "Anonymous Coward" 2> "$tmp"
dialog --msgbox "Your name is `cat "$tmp"`" 8 70
rm "$tmp"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment