tomb notify command for external calls from tomb-open

This commit is contained in:
Jaromil 2011-01-19 12:54:43 +01:00
parent 4475af91a6
commit b40dcff457
2 changed files with 8 additions and 5 deletions

View File

@ -219,13 +219,16 @@ while true; do
-s) SIZE=$2; shift 2 ;;
-k) KEY=$2; shift 2 ;;
--) shift; break ;;
*) CMD=$1; FILE=$2; MOUNT=$3; break ;;
*) CMD=$1;
FILE=$2; MOUNT=$3; # compat with old args
CMD2=${2}; CMD3=${3}; break ;;
esac
done
if [ -z $CMD ]; then
error "first argument missing, use -h for help"
tomb-notify
exit 0
fi
@ -619,7 +622,7 @@ case "$CMD" in
install) install ;;
status) tomb-status ;;
notify) tomb-notify ;;
notify) tomb-notify $CMD2 $CMD3 ;;
*) error "command \"$CMD\" not recognized"
act "try -h for help"

View File

@ -49,7 +49,7 @@ if [ -d $1 ]; then
try rox; if [ $? = 0 ]; then rox ${1}; exit 0; fi
try fsviewer; if [ $? = 0 ]; then fsviewer ${1}; exit 0; fi
try xnc; if [ $? = 0 ]; then xnc ${1}; exit 0; fi
tomb-notify "File manager not found." "Tomb cannot guess which filemanager you are using"
tomb notify "File manager not found." "Tomb cannot guess which filemanager you are using"
exit 1
fi
@ -60,7 +60,7 @@ if [ -f $1 ]; then
tomb -S mount $1
exit $?
else
tomb-notify "Not a real Tomb." "We found no real bones in there."
tomb notify "Not a real Tomb." "We found no real bones in there."
exit 1
fi
fi
@ -77,7 +77,7 @@ if [ "$1" != "create" ]; then
fi
# start guided tomb creation
tomb-notify
tomb -S notify
cat <<EOF
Create a new Tomb
=================