summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdmt/dmt12
1 files changed, 11 insertions, 1 deletions
diff --git a/dmt/dmt b/dmt/dmt
index 7923580..ca44b78 100755
--- a/dmt/dmt
+++ b/dmt/dmt
@@ -65,4 +65,14 @@ api_job() {
fi
}
-api_job
+api_log() {
+ [ -z "$1" ] && job="$(newest_job)" || job="$1"
+ jobdir="$CYCHE_LOG_DIR/$job"
+
+ if [ -d "$jobdir" ]; then
+ printf 'Content-type: text/plain\n\n'
+ cat "$jobdir/log"
+ fi
+}
+
+api_log