[reproducible-website] 01/01: successfully force ordering

Valerie R Young spectranaut at riseup.net
Tue Dec 20 02:34:57 UTC 2016


This is an automated email from the git hooks/post-receive script.

spectranaut-guest pushed a commit to branch master
in repository reproducible-website.

commit 9d2d8ba203285d34d4efbe166efcfb16ae3f57bd
Author: Valerie R Young <spectranaut at riseup.net>
Date:   Mon Dec 19 21:34:35 2016 -0500

    successfully force ordering
---
 _includes/header.html | 3 ++-
 docs.html             | 1 +
 events.html           | 1 +
 index.html            | 6 +++---
 news.html             | 1 +
 resources.html        | 1 +
 tools.html            | 1 +
 who.html              | 1 +
 8 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/_includes/header.html b/_includes/header.html
index 3dd4cfc..efba44a 100644
--- a/_includes/header.html
+++ b/_includes/header.html
@@ -1,3 +1,4 @@
+{% assign sorted_pages = site.pages | sort:"order" %}
 <header class="site-header">
   <div class="container">
     <div class="row">
@@ -16,7 +17,7 @@
           </svg>
         </a>
         <div class="trigger">
-          {% for page in site.pages %}
+          {% for page in sorted_pages | sort:"order" %}
             {% if page.title %}<a class="page-link" href="{{ page.url | prepend: site.baseurl }}">{{ page.title }}</a>{% endif %}
           {% endfor %}
         </div>
diff --git a/docs.html b/docs.html
index cd81b1b..c40f334 100644
--- a/docs.html
+++ b/docs.html
@@ -2,6 +2,7 @@
 layout: page
 title: Documentation
 permalink: /docs/
+order: 1
 ---
 
 <div class="row">
diff --git a/events.html b/events.html
index ec8b562..c75d788 100644
--- a/events.html
+++ b/events.html
@@ -2,6 +2,7 @@
 layout: page
 title: Events
 permalink: /events/
+order: 4
 ---
 
 <div class="row">
diff --git a/index.html b/index.html
index d4598da..e782caf 100644
--- a/index.html
+++ b/index.html
@@ -1,17 +1,17 @@
 ---
 layout: home
 ---
-
+{% assign sorted_pages = site.pages | sort:"order" %}
 <nav>
   <div class="hide-on-mobiles">
-    {% for page in site.pages %}
+    {% for page in sorted_pages %}
       {% if page.title %}<a class="page-link" href="{{ page.url | prepend: site.baseurl }}">{{ page.title }}</a>{% endif %}
     {% endfor %}
   </div>
   <div class="show-on-mobiles">
     <select onchange="if (this.value) window.location.href=this.value">
       <option value="">reproducible-builds.org</option>
-      {% for page in site.pages %}
+      {% for page in sorted_pages %}
         {% if page.title %}<option value="{{ page.url | prepend: site.baseurl }}">{{ page.title }}</option>{% endif %}
       {% endfor %}
     </select>
diff --git a/news.html b/news.html
index b1577b2..7ce78e8 100644
--- a/news.html
+++ b/news.html
@@ -2,6 +2,7 @@
 layout: page
 title: News
 permalink: /news/
+order: 6
 ---
 
 {% for post in site.posts %}
diff --git a/resources.html b/resources.html
index 66470fd..2f787fe 100644
--- a/resources.html
+++ b/resources.html
@@ -2,6 +2,7 @@
 layout: page
 title: Talks & Resources
 permalink: /resources/
+order: 2
 ---
 
 <div class="row">
diff --git a/tools.html b/tools.html
index b07d407..029151d 100644
--- a/tools.html
+++ b/tools.html
@@ -2,6 +2,7 @@
 layout: page
 title: Tools
 permalink: /tools/
+order: 3
 ---
 <div class="row">
   <div class="four columns"> </div>
diff --git a/who.html b/who.html
index 704d53a..a4577b2 100644
--- a/who.html
+++ b/who.html
@@ -2,6 +2,7 @@
 layout: page
 title:  Who is involved?
 permalink: /who/
+order: 5
 ---
 
 <div class="row">

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/reproducible-website.git



More information about the Reproducible-commits mailing list