mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-05 09:14:03 +00:00
364c8e85fb
Submitted by: "Anatoly A. Orehovsky" <tolik@mpeks.tomsk.su>
28 lines
533 B
Bash
Executable File
28 lines
533 B
Bash
Executable File
#!/bin/sh
|
|
DIALOG=${DIALOG=/usr/bin/dialog}
|
|
|
|
find -xd / -type d > /tmp/ftreebox.tmp.$$
|
|
|
|
$DIALOG --clear --title "FTREE BOX" \
|
|
--hline "Press arrows, TAB or Enter" \
|
|
--hfile "../COPYING" \
|
|
--ftree "/tmp/ftreebox.tmp.$$" "/" \
|
|
"This is ftree box" \
|
|
-1 -1 10 2>/tmp/ftree.tmp.$$
|
|
|
|
retval=$?
|
|
|
|
choice=`cat /tmp/ftree.tmp.$$`
|
|
|
|
case $retval in
|
|
0)
|
|
echo "'$choice' chosen.";;
|
|
1)
|
|
echo "Cancel pressed.";;
|
|
255)
|
|
[ -z "$choice" ] || echo $choice ;
|
|
echo "ESC pressed.";;
|
|
esac
|
|
|
|
rm -f /tmp/ftreebox.tmp.$$ /tmp/ftree.tmp.$$
|