Skip to content

Commit 713d0a6

Browse files
committed
Restructure tutorials homepage (fixes ev3dev#243)
1 parent 0e3a0f2 commit 713d0a6

33 files changed

+83
-52
lines changed

_data/tutorial-groups.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
- id: networking
2+
title: Networking
3+
description: "Connecting ev3dev to a local network or the internet, and connecting to an ev3dev device from a PC."
4+
- id: system
5+
title: "Ev3dev System"
6+
description: "Configuring, updating and modifying an ev3dev installation."
7+
- id: website
8+
title: This Website
9+
description: "Using this website and contributing content."
10+
- id: hardware-motors
11+
title: "Using Motors"
12+
description: "Configuring and using motors on ev3dev, from the basic tacho motors to more complex third-party ones."
13+
- id: hardware-extras
14+
title: Extra Hardware
15+
description: "Configuration and usage of specialty and otherwise nonstandard hardware."
16+
- id: software-languages
17+
title: Programming Languages and Tooling
18+
description: "Configuring a development environment, installing new languages, and using advanced language tools."
19+
- id: software-editors
20+
title: "Text Editors"
21+
description: "Tips on using text editors which ship with ev3dev out-of-the-box."
22+
- id: cross-compiling
23+
title: Cross-Compiling Code
24+
description: "Compiling code to run on an EV3 or other ev3dev device from a host PC."
25+
- id: sd-card-image
26+
title: SD Card Imaging
27+
description: "Deprecated guides on flashing an SD card with ev3dev images."

_includes/head.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<link rel='stylesheet' type='text/css' href='http://www.x3dom.org/download/x3dom.css'>
2323
<script type='text/javascript' src='http://www.x3dom.org/download/x3dom.js'></script>
2424
{% endif %}
25-
25+
2626
<!-- Custom styles -->
2727
<link rel="stylesheet" href="/stylesheets/site-structure.css">
2828
<link rel="stylesheet" href="/stylesheets/search.css">
@@ -33,7 +33,7 @@
3333

3434
<!-- Python code highlighting -->
3535
<link rel="stylesheet" href="/stylesheets/pygments/monokai.css" />
36-
36+
3737
<!-- 3rd-party libraries -->
3838
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script>
3939
<script src="/javascripts/bootstrap/bootstrap.min.js"></script>
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{% include icon.html type="info" %}
22
There's an easier way to image your SD card! Check out
33
[the "Getting Started" guide](/docs/getting-started#step-2-copy-the-image-on-to-the-sd-card){: .alert-link }
4-
for a cross-platform guide.
4+
for a cross-platform guide. This tutorial isn't being maintained and may not
5+
work.
56
{: .alert .alert-info}

docs/tutorials/adding-new-project.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Adding a New Project
3-
subject: This Website
3+
subject: website
44
---
55

66
We currently have a [projects page] where you can browse projects that have

docs/tutorials/connecting-to-ev3dev-with-ssh.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Connecting to Ev3dev Using SSH
3-
subject: Networking
3+
subject: networking
44
---
55

66
Connecting with SSH will allow you to run commands on the EV3 over the network

docs/tutorials/connecting-to-the-internet-via-bluetooth.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Connecting to the Internet via Bluetooth
3-
subject: Networking
3+
subject: networking
44
---
55

66
{% include icon.html type="warning" %}

docs/tutorials/connecting-to-the-internet-via-usb.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Connecting to the Internet via USB
3-
subject: Networking
3+
subject: networking
44
---
55

66
{% include icon.html type="warning" %}

docs/tutorials/controlling-wedo2-motor.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Controlling a WeDo 2.0 motor
3-
subject: Hardware - WeDo
3+
subject: hardware-extras
44
author: "@JorgePe"
55
---
66

docs/tutorials/getting-started-with-c.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Getting Started with C
3-
subject: Software - C
3+
subject: software-languages
44
author: "@wasabifan"
55
---
66

docs/tutorials/index.html

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,33 @@
44
include_masonry: "true"
55
---
66

7-
{% assign tutorials=site.pages | where: "category", "tutorials" | sort: "subject" | group_by: "subject" %}
7+
These tutorials will walk you through working with a wide range of hardware and
8+
software. If you're looking for help with a specific goal, this is the place to
9+
look!
810

911
<div class="row masonry-container" data-masonry='{ "itemSelector": ".tutorial-panel", "columnWidth": ".grid-sizer", "percentPosition": true }'>
1012
<div class="grid-sizer col-xs-12 col-sm-6 col-md-6"></div>
11-
{% for group in tutorials %}
12-
{% unless group.name == "" %}
13-
<div class="col-xs-12 col-sm-6 col-md-6 tutorial-panel">
14-
<div class="panel panel-default rounded-panel" id="group-{{ group.name | downcase | replace: ' ','-' }}">
15-
<div class="panel-heading">{{ group.name }}</div>
16-
<div class="panel-body">
17-
<ul>
18-
{% assign items = group.items | sort: "title" %}
19-
{% for item in items %}
20-
<li>
21-
<a href="{{ item.url }}">{{ item.title }}</a>
22-
{% if item.subtitle %}
23-
({{ item.subtitle }})
24-
{% endif %}
25-
</li>
26-
{% endfor %}
27-
</ul>
28-
</div>
13+
{% for group in site.data.tutorial-groups %}
14+
<div class="col-xs-12 col-sm-6 col-md-6 tutorial-panel">
15+
<div class="panel panel-default rounded-panel" id="group-{{ group.name | downcase | replace: ' ','-' }}">
16+
<div class="panel-heading">{{ group.title }}</div>
17+
<div class="panel-body">
18+
<p>
19+
{{ group.description }}
20+
</p>
21+
<ul>
22+
{% assign items = site.pages | where: "category", "tutorials" | where: "subject",group.id %}
23+
{% for item in items %}
24+
<li>
25+
<a href="{{ item.url }}">{{ item.title }}</a>
26+
{% if item.subtitle %}
27+
({{ item.subtitle }})
28+
{% endif %}
29+
</li>
30+
{% endfor %}
31+
</ul>
2932
</div>
3033
</div>
31-
{% endunless %}
34+
</div>
3235
{% endfor %}
3336
</div>

0 commit comments

Comments
 (0)