<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -948,6 +948,12 @@ parser.add_option(&quot;--filter-status&quot;,
                   help = &quot;&quot;&quot;does not print a bug if it is in one of 
 the stati specified (column separated) by this option.&quot;&quot;&quot;.replace(&quot;\n&quot;,&quot;&quot;))
 
+parser.add_option(&quot;--filter-tags&quot;,
+                  dest=&quot;filterTags&quot;,
+                  default=&quot;&quot;,
+                  help = &quot;&quot;&quot;Prints only the issues with one of the following
+tags (column separated) associated to it.&quot;&quot;&quot;)
+
 parser.add_option(&quot;--screen-width&quot;,
                   dest=&quot;screenWidth&quot;,
                   default=terminal_width(),
@@ -1041,6 +1047,7 @@ if __name__ == '__main__':
 
         index = 1
         filteredStati = options.filterStatus.split(&quot;:&quot;)
+        wantedTags = dict([(tag,1) for tag in options.filterTags.split(&quot;:&quot;) if tag])
 
         for item in issueSet.shelf.iteritems():
             if &quot;comment&quot; in item[0]:
@@ -1048,6 +1055,12 @@ if __name__ == '__main__':
             issue = item[1].get_data()
             if issue.status in filteredStati:
                 continue
+            if wantedTags and not issue.tags:
+              continue
+            if wantedTags:
+              matchingTags = [tag for tag in issue.tags.split(&quot;, &quot;) if wantedTags.has_key(tag)]
+              if not matchingTags:
+                continue
             formatString = &quot;%4d  %s  %-&quot; + str(titleWidth+len(&quot;Title&quot;)-1) + &quot;s %-6s %5s %6s %s&quot;
             print formatString % \
                 (index, issue.name[:7], issue.title, issue.status,</diff>
      <filename>git-issues</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>1bec1fbc710d28b6d4bc5f16e7a6fdb25565f055</id>
    </parent>
  </parents>
  <author>
    <name>Giulio Eulisse</name>
    <email>giulio.eulisse@cern.ch</email>
  </author>
  <url>http://github.com/ktf/git-issues/commit/d352c9e842ce32ffab6621c290a367c35a4ec0e3</url>
  <id>d352c9e842ce32ffab6621c290a367c35a4ec0e3</id>
  <committed-date>2008-09-12T14:55:10-07:00</committed-date>
  <authored-date>2008-09-12T14:55:10-07:00</authored-date>
  <message>Adds a --filter-tags option to only show issues with a given tag attached.</message>
  <tree>6c4ac07cdad45be0ca4f773cc61ede2e640f1a2f</tree>
  <committer>
    <name>Giulio Eulisse</name>
    <email>giulio.eulisse@cern.ch</email>
  </committer>
</commit>
