]> git.sur5r.net Git - i3/i3.github.io/commitdiff
update docs/i3bar-protocol for the {"version":1} header clarification
authorMichael Stapelberg <michael@stapelberg.de>
Sun, 12 Aug 2012 17:06:59 +0000 (19:06 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Sun, 12 Aug 2012 17:06:59 +0000 (19:06 +0200)
_docs/i3bar-protocol
docs/i3bar-protocol.html

index f66c7a9a6129a8c90b9175aa4a963bbe9ed8c7a2..21ba9aa0f8e350252e1fdbc8f7a8f76b9d125056 100644 (file)
@@ -1,7 +1,7 @@
 i3bar input protocol
 ====================
 Michael Stapelberg <michael@i3wm.org>
 i3bar input protocol
 ====================
 Michael Stapelberg <michael@i3wm.org>
-February 2012
+August 2012
 
 This document explains the protocol in which i3bar expects its input. It
 provides support for colors, urgency, shortening and easy manipulation.
 
 This document explains the protocol in which i3bar expects its input. It
 provides support for colors, urgency, shortening and easy manipulation.
@@ -49,6 +49,9 @@ consists of a single JSON hash:
 { "version": 1 }
 ----------------
 
 { "version": 1 }
 ----------------
 
+(Note that before i3 v4.3 the precise format had to be +{"version":1}+,
+byte-for-byte.)
+
 What follows is an infinite array (so it should be parsed by a streaming JSON
 parser, but as described above you can go for a simpler solution), whose
 elements are one array per status line. A status line is one unit of
 What follows is an infinite array (so it should be parsed by a streaming JSON
 parser, but as described above you can go for a simpler solution), whose
 elements are one array per status line. A status line is one unit of
@@ -86,6 +89,10 @@ Please note that this example was pretty printed for human consumption.
 i3status and others will output single statuslines in one line, separated by
 \n.
 
 i3status and others will output single statuslines in one line, separated by
 \n.
 
+You can find an example of a shell script which can be used as your
++status_command+ in the bar configuration at
+http://code.stapelberg.de/git/i3/tree/contrib/trivial-bar-script.sh?h=next
+
 === Blocks in detail
 
 full_text::
 === Blocks in detail
 
 full_text::
index c64aafeac35d5c4f4582430cd23956e1ac91c4a4..19660d52b265dbaa146668eb28df3b47e32e9cdf 100644 (file)
@@ -4,7 +4,7 @@
 <head>\r
 <link rel="icon" type="image/png" href="/favicon.png">\r
 <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />\r
 <head>\r
 <link rel="icon" type="image/png" href="/favicon.png">\r
 <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />\r
-<meta name="generator" content="AsciiDoc 8.6.4" />\r
+<meta name="generator" content="AsciiDoc 8.6.7" />\r
 <title>i3: i3bar input protocol</title>\r
 <link rel="stylesheet" href="/css/style.css" type="text/css" />\r
 <link rel="stylesheet" href="/css/xhtml11.css" type="text/css" />\r
 <title>i3: i3bar input protocol</title>\r
 <link rel="stylesheet" href="/css/style.css" type="text/css" />\r
 <link rel="stylesheet" href="/css/xhtml11.css" type="text/css" />\r
@@ -31,7 +31,7 @@ window.onload = function(){asciidoc.footnotes();}
 <h1>i3bar input protocol</h1>\r
 <span id="author">Michael Stapelberg</span><br />\r
 <span id="email"><tt>&lt;<a href="mailto:michael@i3wm.org">michael@i3wm.org</a>&gt;</tt></span><br />\r
 <h1>i3bar input protocol</h1>\r
 <span id="author">Michael Stapelberg</span><br />\r
 <span id="email"><tt>&lt;<a href="mailto:michael@i3wm.org">michael@i3wm.org</a>&gt;</tt></span><br />\r
-<span id="revdate">February 2012</span>\r
+<span id="revdate">August 2012</span>\r
 </div>\r
 <div id="preamble">\r
 <div class="sectionbody">\r
 </div>\r
 <div id="preamble">\r
 <div class="sectionbody">\r
@@ -100,6 +100,8 @@ consists of a single JSON hash:</p></div>
 <div class="content">\r
 <pre><tt>{ "version": 1 }</tt></pre>\r
 </div></div>\r
 <div class="content">\r
 <pre><tt>{ "version": 1 }</tt></pre>\r
 </div></div>\r
+<div class="paragraph"><p>(Note that before i3 v4.3 the precise format had to be <tt>{"version":1}</tt>,\r
+byte-for-byte.)</p></div>\r
 <div class="paragraph"><p>What follows is an infinite array (so it should be parsed by a streaming JSON\r
 parser, but as described above you can go for a simpler solution), whose\r
 elements are one array per status line. A status line is one unit of\r
 <div class="paragraph"><p>What follows is an infinite array (so it should be parsed by a streaming JSON\r
 parser, but as described above you can go for a simpler solution), whose\r
 elements are one array per status line. A status line is one unit of\r
@@ -135,6 +137,9 @@ be represented by a JSON hash:</p></div>
 <div class="paragraph"><p>Please note that this example was pretty printed for human consumption.\r
 i3status and others will output single statuslines in one line, separated by\r
 \n.</p></div>\r
 <div class="paragraph"><p>Please note that this example was pretty printed for human consumption.\r
 i3status and others will output single statuslines in one line, separated by\r
 \n.</p></div>\r
+<div class="paragraph"><p>You can find an example of a shell script which can be used as your\r
+<tt>status_command</tt> in the bar configuration at\r
+<a href="http://code.stapelberg.de/git/i3/tree/contrib/trivial-bar-script.sh?h=next">http://code.stapelberg.de/git/i3/tree/contrib/trivial-bar-script.sh?h=next</a></p></div>\r
 <div class="sect2">\r
 <h3 id="_blocks_in_detail">2.1. Blocks in detail</h3>\r
 <div class="dlist"><dl>\r
 <div class="sect2">\r
 <h3 id="_blocks_in_detail">2.1. Blocks in detail</h3>\r
 <div class="dlist"><dl>\r