script accept report directory as argument, with ~tom/MCO as default
This commit is contained in:
6
check.sh
6
check.sh
@@ -4,7 +4,11 @@ set -u
|
|||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
|
|
||||||
exec 1> $(date -I)_$(hostname).report
|
test $# -lt 1 && dir=/home/tom/MCO || dir=$1
|
||||||
|
|
||||||
|
mkdir -p ${dir} || exit 5
|
||||||
|
|
||||||
|
exec 1> ${dir}/$(date -I)_$(hostname).report
|
||||||
|
|
||||||
echo -ne "\n\n########## $(hostname) ##########\n"
|
echo -ne "\n\n########## $(hostname) ##########\n"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user