File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -102,13 +102,9 @@ parallel_check() {
102102}
103103
104104create_summary () {
105- local d=$(( $end - $start ))
106- local t=" Void Updates for $( date +%Y-%m-%d\ %H:%M\ %Z) (took: ${d} s)"
107105 local f m
108106
109107 {
110- printf ' %s\n%s\n\n' " $t " $( printf %${# t} s | tr ' ' =)
111-
112108 for f in $dest /updates_* .txt; do
113109 if [ -s $f ]; then
114110 m=$( basename ${f%% .txt} | sed ' s/updates_//' )
@@ -123,6 +119,15 @@ create_summary() {
123119 } > $dest .txt
124120}
125121
122+ create_heading () {
123+ local d=$(( $end - $start ))
124+ local t=" Void Updates for $( date +%Y-%m-%d\ %H:%M\ %Z) (took: ${d} s)"
125+ local s
126+ s=$( printf %${# t} s | tr ' ' =)
127+
128+ sed -e " 1s/^/$s \n\n/" -e " 1s/^/$t \n/" -i $dest .txt
129+ }
130+
126131make_current () {
127132 ln -sf $dest .txt $out /$name .txt
128133 ln -sfn $dest $out /$name
@@ -161,7 +166,8 @@ mkdir -p $dest
161166 init_src
162167 update_src
163168 find_pkgs | add_maintainer | parallel_check
164- end=$( date +%s)
165169 create_summary
170+ end=$( date +%s)
171+ create_heading
166172 make_current
167173} 2> $dest /_log.txt
You can’t perform that action at this time.
0 commit comments