ttomb notify command for external calls from tomb-open - tomb - the crypto undertaker
 (HTM) git clone git://parazyd.org/tomb.git
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit b40dcff457419103064d0ade5ed1000bcbdcda07
 (DIR) parent 4475af91a67a08eff77b2ae0d7c6ff7870c21c4e
 (HTM) Author: Jaromil <jaromil@dyne.org>
       Date:   Wed, 19 Jan 2011 12:54:43 +0100
       
       ttomb notify command for external calls from tomb-open
       
       Diffstat:
         M src/tomb                            |       7 +++++--
         M src/tomb-open                       |       6 +++---
       
       2 files changed, 8 insertions(+), 5 deletions(-)
       ---
 (DIR) diff --git a/src/tomb b/src/tomb
       t@@ -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
        
       t@@ -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"
 (DIR) diff --git a/src/tomb-open b/src/tomb-open
       t@@ -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
        
       t@@ -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
       t@@ -77,7 +77,7 @@ if [ "$1" != "create" ]; then
        fi
        
        # start guided tomb creation
       -tomb-notify
       +tomb -S notify
        cat <<EOF
        Create a new Tomb
        =================