public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] sites/www:master commit in: _sass/, bin/, support/use-flags/
@ 2015-07-03 10:19 Alex Legler
  0 siblings, 0 replies; only message in thread
From: Alex Legler @ 2015-07-03 10:19 UTC (permalink / raw
  To: gentoo-commits

commit:     eaff5e2242ca0a3a96bdd80813afd12af7848567
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Fri Jul  3 10:20:38 2015 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Fri Jul  3 10:20:38 2015 +0000
URL:        https://gitweb.gentoo.org/sites/www.git/commit/?id=eaff5e22

Add rudimentary USE flag listing

 _sass/misc.scss              |  6 ++++++
 bin/update-use.sh            |  5 +++++
 bin/update.sh                |  1 +
 support/use-flags/index.html | 50 ++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 62 insertions(+)

diff --git a/_sass/misc.scss b/_sass/misc.scss
index 9808fc0..f816db7 100644
--- a/_sass/misc.scss
+++ b/_sass/misc.scss
@@ -102,4 +102,10 @@ body.nav-align-h2 #content h2:first-of-type {
 .site-logo object {
   max-height: 58px;
   overflow: hidden;
+.use-flag {
+  width: 25%;
+}
+
+.use-desc {
+  width: 75%;
 }
\ No newline at end of file

diff --git a/bin/update-use.sh b/bin/update-use.sh
new file mode 100755
index 0000000..b825c3b
--- /dev/null
+++ b/bin/update-use.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+echo -n 'Updating USE flag information...'
+wget 'https://api.gentoo.org/packages/use.json' -O _data/use.json 2>/dev/null
+echo 'done.'

diff --git a/bin/update.sh b/bin/update.sh
index dcb6f99..35fd32c 100755
--- a/bin/update.sh
+++ b/bin/update.sh
@@ -7,5 +7,6 @@ bin/update-herds.sh || exit 1
 bin/update-mirrors.sh || exit 1
 bin/update-packages.sh || exit 1
 bin/update-planet.sh || exit 1
+bin/update-use.sh || exit 1
 bin/update-userinfo.sh || exit 1
 bin/update-wiki.sh || exit 1

diff --git a/support/use-flags/index.html b/support/use-flags/index.html
new file mode 100644
index 0000000..ea89f74
--- /dev/null
+++ b/support/use-flags/index.html
@@ -0,0 +1,50 @@
+---
+title: 'USE Flag Index'
+navtitle: 'USE Flags'
+nav1: support
+nav2: use
+nav2-show: true
+---
+
+<div class="alert alert-info">
+  <strong>What are USE flags?</strong>
+  <br>
+  For more information on the idea behind USE flags and how to use them,
+  please see <a href="https://wiki.gentoo.org/wiki/Handbook:AMD64/Working/USE" class="alert-link">our documentation</a>.
+</div>
+
+<hr>
+
+<h2>Global USE Flags</h2>
+
+<table class="table table-condensed table-striped">
+  <tr>
+    <th class="use-flag">Flag</th>
+    <th class="use-desc">Description</th>
+  </tr>
+{% for flag in site.data.use.global %}
+  <tr>
+    <th><code>{{ flag[0] }}</code></th>
+    <td>{{ flag[1] }}</td>
+  </tr>
+{% endfor %}
+</table>
+
+<h2>Local USE Flags</h2>
+
+{% for category in site.data.use.local %}
+  <h3 id="{{ category[0] }}">{{ category[0] }}</h3>
+
+  {% for package in category[1] %}
+    <h4 id="{{ category[0] }}/{{ package[0] }}">{{ package[0] }}</h4>
+    
+    <table class="table table-condensed table-striped">
+    {% for flag in package[1] %}
+      <tr>
+        <th class="use-flag"><code>{{ flag[0] }}</code></th>
+        <td class="use-desc">{{ flag[1] }}</td>
+      </tr>
+    {% endfor %}
+    </table>
+  {% endfor %}
+{% endfor %}
\ No newline at end of file


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2015-07-03 10:20 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-03 10:19 [gentoo-commits] sites/www:master commit in: _sass/, bin/, support/use-flags/ Alex Legler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox