[SCM] pkg-kde.alioth.debian.org website branch, master, updated. 4b68dce054b05e1fa14e262522c76830a8c1b948
Eshat Cakar
eshat-guest at alioth.debian.org
Mon Jun 6 09:27:24 UTC 2011
The following commit has been merged in the master branch:
commit 4c08eea501649a59729fe1ebe27c3bf864fd0de0
Author: Eshat Cakar <info at eshat.de>
Date: Mon Jun 6 11:15:01 2011 +0200
Make RSS work right and valid XML.
Use more actual logo on rss and fix tabs
---
genrss.sh | 35 +++++++++++++++--------------------
pages/index | 3 ++-
2 files changed, 17 insertions(+), 21 deletions(-)
diff --git a/genrss.sh b/genrss.sh
index ce13d19..1998f51 100644
--- a/genrss.sh
+++ b/genrss.sh
@@ -2,34 +2,29 @@
FILE=pages/index
-NEWS_START=`grep -n "<h2>Latest" ${FILE} | sed 's/:.*//'`
+NEWS_START=`grep -n "RSS_START" ${FILE} | sed 's/:.*//'`
let "NEWS_START += 1"
-NEWS_END=`tail -n +${NEWS_START} ${FILE} | grep -n "<h2>" | sed 's/:.*//'`
+NEWS_END=`tail -n +${NEWS_START} ${FILE} | grep -n "RSS_END" | sed 's/:.*//'`
-if [ -z "${NEWS_END}" ]
-then
- NEWS_END=`tail -n +${NEWS_START} ${FILE} | wc --lines`
-else
- let "NEWS_END -= 1"
-fi
+let "NEWS_END -= 1"
cat <<__EOHEAD__
<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="2.0">
- <channel>
- <title>Debian KDE maintainers</title>
- <description>Debian KDE news feed</description>
- <link>http://pkg-kde.alioth.debian.org/</link>
- <lastBuildDate>`date -R`</lastBuildDate>
- <generator>bash hacking</generator>
- <image>
- <url>http://pkg-kde.alioth.debian.org/images/KDEbian2-60x60.png</url>
- <title>Debian KDE maintainers</title>
- <link>http://pkg-kde.alioth.debian.org/</link>
- <description>Debian KDE news feed</description>
- </image>
+<channel>
+<title>Debian KDE maintainers</title>
+<description>Debian KDE news feed</description>
+<link>http://pkg-kde.alioth.debian.org/</link>
+<lastBuildDate>`date -R`</lastBuildDate>
+<generator>bash hacking</generator>
+<image>
+ <url>http://pkg-kde.alioth.debian.org/images/kdedebianlogo2_64.png</url>
+ <title>Debian KDE maintainers</title>
+ <link>http://pkg-kde.alioth.debian.org/</link>
+ <description>Debian KDE news feed</description>
+</image>
__EOHEAD__
tail -n +${NEWS_START} ${FILE} | head -n +${NEWS_END} | sed 's/<a[^>]*>//g' | sed 's/<\/a[^>]*>//g' | sed 's,<p>,<item>,g;s,</p>,</description></item>,g;s,<strong>,<title>,g;s,</strong>,</title>,g;s,<br />,<link>http://pkg-kde.alioth.debian.org/</link><description>,g'
diff --git a/pages/index b/pages/index
index 8ada2b7..6f5295d 100644
--- a/pages/index
+++ b/pages/index
@@ -6,7 +6,7 @@
</p>
<h2>Latest news:</h2>
-
+<!--RSS_START-->
<p><strong>May 27, 2011</strong><br />
KDE SC 4.6.3 was <a href="http://lists.debian.org/debian-kde/2011/05/msg00034.html">uploaded to
unstable</a>. Enjoy!
@@ -49,5 +49,6 @@
KDE 4.4.0 is being worked on but it will take some time until it lands on your Debian mirror.
</p>
+<!--RSS_END-->
<p>See <a href="oldnews.html">old news.</a></p>
--
pkg-kde.alioth.debian.org website
More information about the pkg-kde-commits
mailing list