1 |
Author: ulm |
2 |
Date: 2009-10-08 07:33:57 +0000 (Thu, 08 Oct 2009) |
3 |
New Revision: 684 |
4 |
|
5 |
Modified: |
6 |
trunk/modules/news.eselect |
7 |
Log: |
8 |
Really remove leading zeros in numeric month. |
9 |
|
10 |
Modified: trunk/modules/news.eselect |
11 |
=================================================================== |
12 |
--- trunk/modules/news.eselect 2009-10-08 06:54:12 UTC (rev 683) |
13 |
+++ trunk/modules/news.eselect 2009-10-08 07:33:57 UTC (rev 684) |
14 |
@@ -131,7 +131,7 @@ |
15 |
# "date -d" is not portable, therefore we do manual processing |
16 |
if [[ ${posted} == +([0-9])-+([0-9])-+([0-9]) ]]; then |
17 |
year=${posted%%-*} |
18 |
- month=${posted#*-*(0)}; month=${month%%-*} |
19 |
+ month=${posted#*-}; month=${month%%-*} |
20 |
day=${posted##*-} |
21 |
fi |
22 |
wd=$(day_of_week "${year}" "${month}" "${day}") |
23 |
@@ -148,11 +148,11 @@ |
24 |
&& name=$(rfc2047_encode "${name}") |
25 |
[[ ${title} != *([[:ascii:]]) ]] && title=$(rfc2047_encode "${title}") |
26 |
|
27 |
- echo "From ${addr} ${wd} ${mname[month]} ${day} ${time} ${year}" |
28 |
+ echo "From ${addr} ${wd} ${mname[${month##*(0)}]} ${day} ${time} ${year}" |
29 |
echo "From: ${name}${name+ }<${addr}>" |
30 |
#echo "Reply-To: DO NOT REPLY <devnull@×××××××××.invalid>" |
31 |
echo "Subject: ${title}" |
32 |
- echo "Date: ${wd}, ${day} ${mname[month]} ${year} ${time} +0000" |
33 |
+ echo "Date: ${wd}, ${day} ${mname[${month##*(0)}]} ${year} ${time} +0000" |
34 |
echo "Message-Id: <glep42-${item}@gentoo.org>" |
35 |
echo "MIME-Version: 1.0" |
36 |
echo "Content-Type: text/plain; charset=UTF-8" |