Skip to content

Commit 3e83f8c

Browse files
committed
toc regex, author line, venkat article
1 parent 211e94c commit 3e83f8c

File tree

8 files changed

+25
-5
lines changed

8 files changed

+25
-5
lines changed

app/data/authors.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,13 @@
2929
description: |
3030
José is a cool guy.
3131
and here's more text.
32-
thanks.
32+
thanks.
33+
34+
- name: Venkat Subramaniam
35+
email: venkats@agiledeveloper.com
36+
photo_url: https://itkonekt.com/media/2019/12/Venkat.png
37+
github: venkats
38+
twitter: venkat_s
39+
website: https://agiledeveloper.com/
40+
description: |
41+
Venkat Placeholder.

app/pages/learn/01_tutorial/03_getting-to-know-the-language/03_refactoring_to_functional_style/00_refactoring.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ layout: learn/tutorial-group-top.html
1010
subheader_select: tutorials
1111
main_css_id: learn
1212
description: "Learning to change code from the Imperative to the Functional Style."
13+
author: ["VenkatSubramaniam"]
1314
---
1415

1516
This part of the tutorial helps you to learn the functional style equivalent of the imperative style code we often find. As you move forward in your projects, wherever it makes sense, you can change imperative style code to functional style code using the mappings you learn in this tutorial.
@@ -18,5 +19,5 @@ In this series we cover the following conversions from the imperative to the fun
1819

1920
| Tutorial |Imperative Style | Functional Style Equivalent |
2021
|------------------------------------------------------|-----------------|------------------------------|
21-
| [Converting Simple Loops](#refactoring.simple.loops) | `for()` | `range()` or `rangeClosed()` |
22+
| [Converting Simple Loops](id:refactoring.simple.loops) | `for()` | `range()` or `rangeClosed()` |
2223

app/pages/learn/01_tutorial/03_getting-to-know-the-language/03_refactoring_to_functional_style/01_converting_simple_loops.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ toc:
1313
- Mappings {mappings}
1414
description: "Converting Simple Imperative Loops to Functional Style."
1515
last_update: 2023-07-06
16+
author: ["VenkatSubramaniam"]
1617
---
1718

1819
<a id="styles">&nbsp;</a>

app/templates/pages/learn/tutorial-group-top.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@
1919

2020
<h1>{{ file.fm.title_html | safe }}</h1>
2121

22+
{% if file.fm.author %}
23+
{% include "app/templates/partials/_author.html" %}
24+
{% endif %}
25+
2226
<p>{{ contents | safe }}</p>
2327

2428
<br />

app/templates/pages/learn/tutorial-group.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,10 @@
3535

3636
<h1>{{ file.fm.title_html | safe }}</h1>
3737

38+
{% if file.fm.author %}
39+
{% include "app/templates/partials/_author.html" %}
40+
{% endif %}
41+
3842
<div class="row">
3943
<div id="content" class="col-9">
4044
<div class="line-numbers">

app/templates/pages/learn/tutorial.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,7 @@
1919
<h1>{{ file.fm.title_html | safe }}</h1>
2020

2121
{% if file.fm.author %}
22-
This page was contributed by <a href="/author/{{ file.fm.author }}">{{ file.data.authorsMap[file.fm.author].name }}</a> under the <a href="https://oss.oracle.com/licenses/upl/">UPL</a>
23-
<br />
22+
{% include "app/templates/partials/_author.html" %}
2423
{% endif %}
2524

2625
<div class="row">
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
This page was contributed by <a href="/author/{{ file.fm.author }}">{{ file.data.authorsMap[file.fm.author].name }}</a> under the <a href="https://oss.oracle.com/licenses/upl/">UPL</a>
2+
<br />

gulpfile.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ function pages() {
284284

285285
.pipe(data(function (file) {
286286
if (file.fm.toc) {
287-
const section_name_regex = /^[\s|\w|/|,]+[^{|^\s{]+/;
287+
const section_name_regex = /^[\s\w.,|]+[^{|^\s{]+/;
288288
const anchor_regex = /{([^{|^}]+)}/;
289289
file.fm.toc = file.fm.toc
290290
.map(entry => ({

0 commit comments

Comments
 (0)