[PATCH v2 13/20] nmbug-status: Convert from XHTML 1.0 to HTML 5
authorW. Trevor King <wking@tremily.us>
Mon, 10 Feb 2014 18:40:34 +0000 (10:40 +1600)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:59:52 +0000 (09:59 -0800)
37/5d4526242d72002c8e0a27ed7e15192922fff3 [new file with mode: 0644]

diff --git a/37/5d4526242d72002c8e0a27ed7e15192922fff3 b/37/5d4526242d72002c8e0a27ed7e15192922fff3
new file mode 100644 (file)
index 0000000..d403207
--- /dev/null
@@ -0,0 +1,114 @@
+Return-Path: <wking@tremily.us>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 87F22429E51\r
+       for <notmuch@notmuchmail.org>; Mon, 10 Feb 2014 10:42:28 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References"\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0 tagged_above=-999 required=5\r
+       tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001]\r
+       autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id QZt9ckPD2I6m for <notmuch@notmuchmail.org>;\r
+       Mon, 10 Feb 2014 10:42:21 -0800 (PST)\r
+Received: from qmta05.westchester.pa.mail.comcast.net\r
+       (qmta05.westchester.pa.mail.comcast.net [76.96.62.48])\r
+       by olra.theworths.org (Postfix) with ESMTP id C3E92429E27\r
+       for <notmuch@notmuchmail.org>; Mon, 10 Feb 2014 10:41:59 -0800 (PST)\r
+Received: from omta06.westchester.pa.mail.comcast.net ([76.96.62.51])\r
+       by qmta05.westchester.pa.mail.comcast.net with comcast\r
+       id QcnL1n00616LCl055ihz3X; Mon, 10 Feb 2014 18:41:59 +0000\r
+Received: from odin.tremily.us ([24.18.63.50])\r
+       by omta06.westchester.pa.mail.comcast.net with comcast\r
+       id Qihy1n005152l3L3SihyP1; Mon, 10 Feb 2014 18:41:59 +0000\r
+Received: from mjolnir.tremily.us (unknown [192.168.0.140])\r
+       by odin.tremily.us (Postfix) with ESMTPS id D732110167BB;\r
+       Mon, 10 Feb 2014 10:41:57 -0800 (PST)\r
+Received: (nullmailer pid 1272 invoked by uid 1000);\r
+       Mon, 10 Feb 2014 18:40:45 -0000\r
+From: "W. Trevor King" <wking@tremily.us>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH v2 13/20] nmbug-status: Convert from XHTML 1.0 to HTML 5\r
+Date: Mon, 10 Feb 2014 10:40:34 -0800\r
+Message-Id:\r
+ <a913793a12b3138ee34d24439510200f5024e306.1392056624.git.wking@tremily.us>\r
+X-Mailer: git-send-email 1.8.5.2.8.g0f6c0d1\r
+In-Reply-To: <cover.1392056624.git.wking@tremily.us>\r
+References: <cover.1392056624.git.wking@tremily.us>\r
+In-Reply-To: <cover.1392056624.git.wking@tremily.us>\r
+References: <cover.1392056624.git.wking@tremily.us>\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net;\r
+       s=q20121106; t=1392057719;\r
+       bh=I5ipKx+pLBmLrqM33TyIDrX53+gJGl8ca+THjVP1B34=;\r
+       h=Received:Received:Received:Received:From:To:Subject:Date:\r
+       Message-Id;\r
+       b=kwc7Q0zV5ir5AjhbAmqP+fdU4CYszkaLYpcNNElcSd5njvlZUwt21h8EfJp+aOw1e\r
+       vFpDJzpAOf9oI+u1IoZdTFNGeFKu8ynGgFSypbNYkiZjI0rgsNptyniM/1oEvUDtxW\r
+       B2B2Qn56umepUzWpP+EeOupcuLOG1R74GP/rUO/F87aXT87Z0sm5ymO+P0kBZ8DOtx\r
+       IXZmVWjW3m0g5KgEuF2ZhxcrVUt9xfqacmTyYjp4YmcitAXoBk22cAF+F0w7N/oed2\r
+       YWVWCVen3617pgsMKEFc8HYyspuCFuvp9YDy5iY3VKznQWZ4yqVxCA+prBoF+XEexE\r
+       ifbvZ+jLpkaXg==\r
+Cc: Tomi Ollila <tomi.ollila@iki.fi>\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 10 Feb 2014 18:42:28 -0000\r
+\r
+HTML 5 for the win :).  I also de-namespaced the language; the HTML 5\r
+spec allows a vestigial xml:lang attribute, but it's a no-op [1], so I\r
+stripped it.\r
+\r
+This shouldn't break anything at tethera, which already serves the\r
+status as text/html:\r
+\r
+  $ wget -S http://nmbug.tethera.net/status/\r
+  --2014-02-02 21:20:39--  http://nmbug.tethera.net/status/\r
+  Resolving nmbug.tethera.net... 87.98.215.224\r
+  Connecting to nmbug.tethera.net|87.98.215.224|:80... connected.\r
+  HTTP request sent, awaiting response...\r
+    HTTP/1.1 200 OK\r
+    Vary: Accept-Encoding\r
+    Content-Type: text/html\r
+  ...\r
+\r
+This also matches the Content-Type in the generated HTML's http-equiv\r
+meta.\r
+\r
+[1]: http://www.w3.org/TR/html5/dom.html#the-lang-and-xml:lang-attributes\r
+---\r
+ devel/nmbug/nmbug-status | 5 ++---\r
+ 1 file changed, 2 insertions(+), 3 deletions(-)\r
+\r
+diff --git a/devel/nmbug/nmbug-status b/devel/nmbug/nmbug-status\r
+index 20e2447..873a46a 100755\r
+--- a/devel/nmbug/nmbug-status\r
++++ b/devel/nmbug/nmbug-status\r
+@@ -227,9 +227,8 @@ class HtmlPage (Page):\r
\r
+ _PAGES['text'] = Page()\r
+ _PAGES['html'] = HtmlPage(\r
+-    header='''<?xml version="1.0" encoding="utf-8" ?>\r
+-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\r
+-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">\r
++    header='''<!DOCTYPE html>\r
++<html lang="en">\r
+ <head>\r
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />\r
+ <title>Notmuch Patches</title>\r
+-- \r
+1.8.5.2.8.g0f6c0d1\r
+\r