|
|
|
@ -1,4 +1,4 @@ |
|
|
|
#!/bin/bash |
|
|
|
#!/usr/bin/env bash |
|
|
|
|
|
|
|
# CONSTANTS |
|
|
|
DEBUG=true |
|
|
|
@ -10,10 +10,6 @@ SCRIPT=$1 |
|
|
|
function exit { |
|
|
|
code=${1:-0} |
|
|
|
|
|
|
|
# a bit of magic: read content of file still on write! |
|
|
|
# count=$(wc -c $TMP_ERROR | cut -d' ' -f1) |
|
|
|
# content=$(head -qc$count $TMP_ERROR) |
|
|
|
|
|
|
|
if [[ -s $TMP_ERROR ]]; then |
|
|
|
content=$(<$TMP_ERROR) |
|
|
|
$DEBUG && >/dev/tty echo '---stderr---' |