some changes to the briefing system
This commit is contained in:
parent
c015833774
commit
ce0b116cbb
|
@ -1,4 +1,5 @@
|
||||||
path = "~/vdir/calendar/personal/*"
|
path = "~/vdir/calendar/personal/*"
|
||||||
date_format = "%m-%d-%Y"
|
date_format = "%m-%d-%Y"
|
||||||
time_format = "%H:%M"
|
time_format = "%H:%M"
|
||||||
|
default_due = 0
|
||||||
default_list = "edfbeaf1-e9f3-4d94-a512-40cdafdbc7a0"
|
default_list = "edfbeaf1-e9f3-4d94-a512-40cdafdbc7a0"
|
||||||
|
|
|
@ -11,6 +11,7 @@ cat > main.tex <<EOF
|
||||||
\documentclass[oneside]{article}
|
\documentclass[oneside]{article}
|
||||||
|
|
||||||
\usepackage{amssymb}
|
\usepackage{amssymb}
|
||||||
|
\usepackage[left=1.5cm, right=1.5cm, top=1.5cm, bottom=1.5cm]{geometry}
|
||||||
|
|
||||||
\pagenumbering{gobble}
|
\pagenumbering{gobble}
|
||||||
|
|
||||||
|
@ -30,13 +31,13 @@ cat > main.tex <<EOF
|
||||||
|
|
||||||
\vspace{-0.30cm}
|
\vspace{-0.30cm}
|
||||||
|
|
||||||
\noindent \rule{12cm}{0.4pt}
|
\noindent \rule{\textwidth}{0.4pt}
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
schedule=$(
|
schedule=$(
|
||||||
khal list today today --format "{categories}|{start-time}|{end-time}|{title}" |
|
khal list today today --format "{calendar}|{categories}|{start-time}|{end-time}|{title}" |
|
||||||
grep '^school|'
|
grep -E '^home\|school\||band\|'
|
||||||
)
|
)
|
||||||
IFS='
|
IFS='
|
||||||
'
|
'
|
||||||
|
@ -44,7 +45,7 @@ IFS='
|
||||||
for class in $schedule; do
|
for class in $schedule; do
|
||||||
echo "$class" |
|
echo "$class" |
|
||||||
awk -F'|' '{
|
awk -F'|' '{
|
||||||
print "\\noindent " $4 " \\hspace{\\fill} \\textit{(" $2 "-" $3 ")}\n\n"
|
print "\\noindent " $5 " \\hspace{\\fill} \\textit{(" $3 "-" $4 ")}\n\n"
|
||||||
}' >> main.tex
|
}' >> main.tex
|
||||||
done
|
done
|
||||||
|
|
||||||
|
@ -55,7 +56,7 @@ cat >> main.tex <<EOF
|
||||||
|
|
||||||
\vspace{-0.30cm}
|
\vspace{-0.30cm}
|
||||||
|
|
||||||
\noindent \rule{12cm}{0.4pt}
|
\noindent \rule{\textwidth}{0.4pt}
|
||||||
|
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
@ -74,11 +75,38 @@ done
|
||||||
cat >> main.tex <<EOF
|
cat >> main.tex <<EOF
|
||||||
\vspace{0.4cm}
|
\vspace{0.4cm}
|
||||||
|
|
||||||
|
EOF
|
||||||
|
|
||||||
|
# generate notices
|
||||||
|
ssh netbox df -h |
|
||||||
|
grep /dev/vda3 |
|
||||||
|
awk -F' ' '{print "\\item \\texttt{" $1 "} on \\texttt{netbox} is at " $5 " utilization."}' |
|
||||||
|
sed 's/\%/\\%/g' > notices.tex
|
||||||
|
|
||||||
|
if [ -f notices.tex ]; then
|
||||||
|
cat >> main.tex <<EOF
|
||||||
|
\noindent \textsc{Procedural Notices}
|
||||||
|
|
||||||
|
\vspace{-0.30cm}
|
||||||
|
|
||||||
|
\noindent \rule{\textwidth}{0.4pt}
|
||||||
|
|
||||||
|
\begin{enumerate}
|
||||||
|
|
||||||
|
\input{notices}
|
||||||
|
|
||||||
|
\end{enumerate}
|
||||||
|
|
||||||
|
\vspace{0.4cm}
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
cat >> main.tex <<EOF
|
||||||
\noindent \textsc{Items to be Appended to the Agenda}
|
\noindent \textsc{Items to be Appended to the Agenda}
|
||||||
|
|
||||||
\vspace{-0.30cm}
|
\vspace{-0.30cm}
|
||||||
|
|
||||||
\noindent \rule{12cm}{0.4pt}
|
\noindent \rule{\textwidth}{0.4pt}
|
||||||
|
|
||||||
\end{document}
|
\end{document}
|
||||||
EOF
|
EOF
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
generate_daily_brief | tail -1 | sed 's|file://||g' | xargs lp -d EPSONTHING
|
Loading…
Reference in New Issue