source: configs/testing/bash/post.sh @ 502

Last change on this file since 502 was 502, checked in by dubos, 7 years ago

configs/testing : towards first working version

File size: 1.4 KB
Line 
1#!/bin/bash
2
3function all_results()
4{
5    cd $ROOT/RUNS
6    for TEST in * ; do
7        NAME=$(echo $TEST | tr _ /)
8        echo "\subsection{$NAME}"
9        for GRAPH in $TEST/*.png ; do
10            cat <<EOF
11\begin{figure}
12\centering{}
13\includegraphics[scale=0.5]{$ROOT/RUNS/$GRAPH}
14\end{figure}
15EOF
16        done
17    done
18#    cd $ROOT/tmp
19}
20
21function all_params()
22{
23    cd $ROOT/RUNS
24    for TEST in * ; do
25        NAME=$(echo $TEST | tr _ /)
26        cat <<EOF
27\subsection{$NAME}
28\begin{lstlisting}
29$(cat $TEST/run.def)
30\end{lstlisting}
31EOF
32    done
33#    cd $ROOT/tmp
34}
35
36ROOT=$PWD
37
38for dir in $ROOT/RUNS/* ; do
39    cd $dir
40    echo
41    pwd
42    ls -l post.py netcdf
43    python post.py &
44done
45wait
46
47cd $ROOT/tmp
48rm -f *.aux *.log *.toc *.tex
49
50cat <<EOF >report.tex
51\documentclass[a4paper,english]{article}
52\usepackage{graphicx}
53\usepackage{listings}
54\usepackage[T1]{fontenc}
55\usepackage[latin9]{inputenc}
56\usepackage{color}
57\usepackage{babel}
58\usepackage[unicode=true,pdfusetitle,
59 bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
60 breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=true]
61 {hyperref}
62
63\begin{document}
64
65\title{DYNAMICO correctness report ($arch)}
66\author{Thomas Dubos}
67\maketitle
68\tableofcontents{}
69\section{Results}
70$(all_results)
71\section{Parameters}
72$(all_params)
73\end{document}
74EOF
75
76pdflatex report.tex >/dev/null
77pdflatex report.tex >/dev/null
78mailx -s "DYNAMICO correctness report " -a report.pdf dubos@lmd.polytechnique.fr </dev/null
Note: See TracBrowser for help on using the repository browser.