for parallel gencharts
This commit is contained in:
parent
62eb075739
commit
8a50defb16
@ -11,8 +11,9 @@ function genchart {
|
|||||||
[ -z "${colors}" ] && colors="White,Gold,Silver,Blue,DarkMagenta,DarkViolet,Indigo,MediumBlue,DarkOrchid,MidnightBlue,CornflowerBlue,CadetBlue,DarkCyan,DarkSlateBlue,DeepSkyBlue,DodgerBlue,Teal"
|
[ -z "${colors}" ] && colors="White,Gold,Silver,Blue,DarkMagenta,DarkViolet,Indigo,MediumBlue,DarkOrchid,MidnightBlue,CornflowerBlue,CadetBlue,DarkCyan,DarkSlateBlue,DeepSkyBlue,DodgerBlue,Teal"
|
||||||
|
|
||||||
local f_tmp="${f_tmp}/$RANDOM"
|
local f_tmp="${f_tmp}/$RANDOM"
|
||||||
local f_tmp_data="${f_tmp}-data"
|
local f_tmp_data="${f_tmp}/g_genchart/data"
|
||||||
local f_tmp_headline="${f_tmp}-headline"
|
local f_tmp_headline="${f_tmp}/g_genchart/headline"
|
||||||
|
local f_tmp_legend="${f_tmp}/g_genchart/legend"
|
||||||
mkdir -p ${f_tmp}/g_genchart
|
mkdir -p ${f_tmp}/g_genchart
|
||||||
|
|
||||||
local awkfields=$(echo "${fields}" | sed 's/,/ \",\" \$/g; s/^/\$/')
|
local awkfields=$(echo "${fields}" | sed 's/,/ \",\" \$/g; s/^/\$/')
|
||||||
@ -59,7 +60,7 @@ function genchart {
|
|||||||
echo "<p class='legend'><font color='${color}'>${linename} (${linelastvalue})</font></p>"
|
echo "<p class='legend'><font color='${color}'>${linename} (${linelastvalue})</font></p>"
|
||||||
else
|
else
|
||||||
echo "<p class='legend'><font color='${linecolor}'>${linename} (${linelastvalue})</font></p>"
|
echo "<p class='legend'><font color='${linecolor}'>${linename} (${linelastvalue})</font></p>"
|
||||||
fi >>${f_tmp}/g_genchart/legend
|
fi >>${f_tmp_legend}
|
||||||
local linenum=1
|
local linenum=1
|
||||||
for line in $(cat ${f_tmp_data})
|
for line in $(cat ${f_tmp_data})
|
||||||
do
|
do
|
||||||
@ -94,7 +95,7 @@ function genchart {
|
|||||||
if grep -q ',' ${f_tmp_headline}
|
if grep -q ',' ${f_tmp_headline}
|
||||||
then
|
then
|
||||||
echo "<td id='noborder'>"
|
echo "<td id='noborder'>"
|
||||||
tac ${f_tmp}/g_genchart/legend
|
tac ${f_tmp_legend}
|
||||||
echo "</td>"
|
echo "</td>"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user