display runtime of script
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
start=`date +%s`
|
||||
|
||||
CURDIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
|
||||
TMP=/tmp/status
|
||||
source "$TMP"
|
||||
@@ -13,6 +15,8 @@ else
|
||||
offlineimap
|
||||
fi
|
||||
|
||||
sync=`date +%s`
|
||||
|
||||
# Index new mails which will be tagged with notmuch's new.tags
|
||||
echo "[DEBUG] Sync notmuch database with new mails"
|
||||
notmuch new
|
||||
@@ -49,4 +53,5 @@ notmuch tag -unread -- path:Trash.ignore-mod/**
|
||||
echo "[DEBUG] Remove the 'new' tag"
|
||||
notmuch tag -new -- tag:new
|
||||
|
||||
echo "[DEBUG] poll.sh exited successfully"
|
||||
end=`date +%s`
|
||||
echo "[DEBUG] poll.sh exited after $((end-start))s ($((sync-start))s download)"
|
||||
|
||||
Reference in New Issue
Block a user