comparison scripts/send.sh @ 191:fea886ba7279

DEP-12: add source for .functions.sh to all scripts using compose
author smith@nwoca.org
date Wed, 20 Sep 2017 17:56:23 +0100
parents 8f45c43ea7a4
children
comparison
equal deleted inserted replaced
190:c3587159637f 191:fea886ba7279
3 # Securely sends a file or standard input to a SSDT web server. 3 # Securely sends a file or standard input to a SSDT web server.
4 # e.g: 4 # e.g:
5 # capture.sh | send.sh - # sends log files to ssdt server for the current project 5 # capture.sh | send.sh - # sends log files to ssdt server for the current project
6 # send.sh docker-compose.yml # sends the compose file 6 # send.sh docker-compose.yml # sends the compose file
7 # 7 #
8 source "$( dirname "${BASH_SOURCE[0]}")/.functions.sh" 8 source "${SSDT_SCRIPTS:-$(dirname "${BASH_SOURCE[0]}")}/.functions.sh"
9 9
10 file=${1?"Usage: $0 filename [name]\n specify the filename relative to the current directory or - for stdin.\noptionally specify a short name (default to base directory)"} 10 file=${1?"Usage: $0 filename [name]\n specify the filename relative to the current directory or - for stdin.\noptionally specify a short name (default to base directory)"}
11 if [ "$file" != "-" ] 11 if [ "$file" != "-" ]
12 then 12 then
13 file="/tmp/${file}" 13 file="/tmp/${file}"