[yelp-tools] yelp-check: Support Mallard Sites for status
- From: Shaun McCance <shaunm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [yelp-tools] yelp-check: Support Mallard Sites for status
- Date: Wed, 1 Jul 2015 02:46:31 +0000 (UTC)
commit 9ed7b7f884b8f30293900cfcb487d262706f0ebe
Author: Shaun McCance <shaunm gnome org>
Date: Tue Jun 30 22:46:11 2015 -0400
yelp-check: Support Mallard Sites for status
tools/yelp-check.in | 12 +++++++++++-
xslt/mal-status.xsl | 4 +++-
2 files changed, 14 insertions(+), 2 deletions(-)
---
diff --git a/tools/yelp-check.in b/tools/yelp-check.in
index ab0130e..64452fa 100755
--- a/tools/yelp-check.in
+++ b/tools/yelp-check.in
@@ -216,6 +216,7 @@ yelp_usage_status () {
echo " matching page is reporting along with its status."
echo ""
echo "Options:"
+ echo " -s Treat pages as belonging to a Mallard site"
echo " --version VER Select revisions with the version attribute VER"
echo " --docversion VER Select revisions with the docversion attribute VER"
echo " --pkgversion VER Select revisions with the pkgversion attribute VER"
@@ -764,6 +765,11 @@ yelp_status () {
fi
while [ "$#" != "0" ]; do
case "$1" in
+ "-s")
+ check_site="1"
+ check_site_root=$(pwd)
+ shift
+ ;;
"--version")
shift
check_version="$1"
@@ -813,7 +819,11 @@ yelp_status () {
exit 1
fi
check_cache_file=`mktemp "${TMPDIR:-/tmp}"/yelp-XXXXXXXX`
- yelp-build cache -o "$check_cache_file" "$@"
+ if [ "x$check_site" = "x1" ]; then
+ yelp-build cache -s -o "$check_cache_file" "$@"
+ else
+ yelp-build cache -o "$check_cache_file" "$@"
+ fi
xsltproc \
--stringparam version "$check_version" \
--stringparam docversion "$check_docversion" \
diff --git a/xslt/mal-status.xsl b/xslt/mal-status.xsl
index 34e75ed..17ca7c7 100644
--- a/xslt/mal-status.xsl
+++ b/xslt/mal-status.xsl
@@ -1,11 +1,11 @@
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:mal="http://projectmallard.org/1.0/"
+ xmlns:site="http://projectmallard.org/site/1.0/"
xmlns:cache="http://projectmallard.org/cache/1.0/"
xmlns:exsl="http://exslt.org/common"
xmlns:str="http://exslt.org/strings"
xmlns:dyn="http://exslt.org/dynamic"
- exclude-result-prefixes="mal cache exsl dyn"
version="1.0">
<xsl:output method="text"/>
@@ -50,6 +50,7 @@
<xsl:template match="/cache:cache">
<xsl:for-each select="mal:page">
+ <xsl:sort select="@site:dir"/>
<xsl:sort select="@id"/>
<xsl:variable name="select">
<xsl:text>mal:info/mal:revision</xsl:text>
@@ -116,6 +117,7 @@
<xsl:if test="$newer = '' or ($revision/@date and
(translate($revision/@date, '-', '') > translate($newer, '-', '')))">
<xsl:if test="$totals != '1'">
+ <xsl:value-of select="@site:dir"/>
<xsl:value-of select="@id"/>
<xsl:text>: </xsl:text>
</xsl:if>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]