Skip to content

Commit 6c743e1

Browse files
committed
modify transition workflow/variables
1. The transtion headers will now have a button that can close them (though its not permenent) 2. The third step of the transition will no longer be coded into the yaml here because the third step of the transition will use the workbench version as the default version. This means that no redirect will be needed. 3. All transition dates will be specified 4. Language has been updated to not refer to "Jekyll" as it may not be immediately obvious that Jekyll was used to build the site.
1 parent 078eec5 commit 6c743e1

File tree

5 files changed

+37
-30
lines changed

5 files changed

+37
-30
lines changed

_includes/check_transition_variables.html

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,21 @@
88
{% endunless %}
99

1010
{% if date == "true" %}
11-
{% unless site.transition_date %}
11+
{% unless site.transition_date_prebeta %}
1212
<div class="alert alert-danger">
13-
you need to specify the variable <code>transition_date</code>
13+
you need to specify the variable <code>transition_date_prebeta</code>
14+
in <code>_config.yml</code>.
15+
</div>
16+
{% endunless %}
17+
{% unless site.transition_date_beta %}
18+
<div class="alert alert-danger">
19+
you need to specify the variable <code>transition_date_beta</code>
20+
in <code>_config.yml</code>.
21+
</div>
22+
{% endunless %}
23+
{% unless site.transition_date_prerelease %}
24+
<div class="alert alert-danger">
25+
you need to specify the variable <code>transition_date_prerelease</code>
1426
in <code>_config.yml</code>.
1527
</div>
1628
{% endunless %}

_includes/lesson_footer.html

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@
2828
{% endif %}
2929
</div>
3030
<div class="col-md-6 help-links" align="right">
31-
{% if site.life_cycle contains 'transition-step' %}
32-
<a href="{{repo_url}}">Edit on GitHub</a>
33-
{% elsif page.source == "Rmd" %}
34-
<a href="{{repo_url}}/edit/{{ default_branch }}/{{page.path|replace: "_episodes", "_episodes_rmd" | replace: ".md", ".Rmd"}}" data-checker-ignore>Edit on GitHub</a>
35-
{% else %}
36-
<a href="{{repo_url}}/edit/{{ default_branch }}/{{page.path}}" data-checker-ignore>Edit on GitHub</a>
37-
{% endif %}
31+
{% if site.life_cycle == 'transition-step-2' %}
32+
<a href="{{repo_url}}">Edit on GitHub</a>
33+
{% elsif page.source == "Rmd" %}
34+
<a href="{{repo_url}}/edit/{{ default_branch }}/{{page.path|replace: "_episodes", "_episodes_rmd" | replace: ".md", ".Rmd"}}" data-checker-ignore>Edit on GitHub</a>
35+
{% else %}
36+
<a href="{{repo_url}}/edit/{{ default_branch }}/{{page.path}}" data-checker-ignore>Edit on GitHub</a>
37+
{% endif %}
3838
/
3939
<a href="{{ repo_url }}/blob/{{ source_branch }}/CONTRIBUTING.md" data-checker-ignore>Contributing</a>
4040
/

_includes/life_cycle.html

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -41,31 +41,30 @@
4141
{% endcomment %}
4242

4343
{% elsif site.life_cycle == "transition-step-1" %}
44-
{% include check_transition_variables.html need_transition_date = 'false' %}
44+
{% include check_transition_variables.html need_transition_date = 'true' %}
4545

4646
<div class="alert alert-warning life-cycle">
47-
A newer version of this lesson is being tested on The Carpentries Workbench:
47+
A snapshot of this lesson from {{ site.transition_date_prebeta }} is being tested on The Carpentries Workbench:
4848
<a href="{{ site.transition_url }}">{{ site.transition_url }}</a>.
49-
The Jekyll version of this lesson will become deprecated in the near future.
49+
<br>
50+
<b>The Workbench version of this lesson will become default on {{ site.transition_date_prerelease }}</b>.
51+
<button type="button" style="border: true; position: absolute; top: 10px; right: 27px; color: #383838;" class="close" data-dismiss="alert" aria-label="Close">
52+
<span aria-hidden="true" style='font-size:34pt'>&times;</span>
53+
</button>
5054
</div>
5155

5256
{% elsif site.life_cycle == "transition-step-2" %}
5357
{% include check_transition_variables.html need_transition_date = 'true' %}
5458

55-
<div class="alert alert-danger life-cycle">
56-
A newer version of this lesson is available from:
57-
<a href="{{ site.transition_url }}">{{ site.transition_url }}</a>.
58-
The Jekyll version of this lesson will become deprecated on
59-
{{ site.transition_date }}.
60-
</div>
61-
62-
{% elsif site.life_cycle == "transition-step-3" %}
63-
{% include check_transition_variables.html need_transition_date = 'false' %}
64-
65-
<div class="alert alert-danger life-cycle">
66-
You are veiwing a deprecated version of this lesson. An updated version is
67-
available from:
59+
<div class="alert alert-danger alert-dismissible life-cycle" role="alert">
60+
This lesson is a <b>snapshot from {{ site.transition_date_beta }}</b>.
61+
A newer version is being tested on The Carpentries Workbench:
6862
<a href="{{ site.transition_url }}">{{ site.transition_url }}</a>.
63+
<br>
64+
The Workbench version of this lesson will become default on <b>{{ site.transition_date_prerelease }}</b>.
65+
<button type="button" style="border: true; position: absolute; top: 10px; right: 27px; color: #383838;" class="close" data-dismiss="alert" aria-label="Close">
66+
<span aria-hidden="true" style='font-size:34pt'>&times;</span>
67+
</button>
6968
</div>
7069

7170
{% endif %}

_includes/navbar.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@
9494

9595
{% comment %} Always show license. {% endcomment %}
9696
<li><a href="{{ relative_root_path }}{% link LICENSE.md %}">License</a></li>
97-
{% if site.life_cycle contains 'transition-step' %}
97+
{% if site.life_cycle == 'transition-step-1' %}
9898
<li><a href="{{repo_url}}">Improve this page <span class="glyphicon glyphicon-pencil" aria-hidden="true"></span></a></li>
9999
{% elsif page.source == "Rmd" %}
100100
<li><a href="{{repo_url}}/edit/{{ default_branch }}/{{page.path|replace: "_episodes", "_episodes_rmd" | replace: ".md", ".Rmd"}}" data-checker-ignore>Improve this page <span class="glyphicon glyphicon-pencil" aria-hidden="true"></span></a></li>

_layouts/base.html

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

2424
{% include favicons.html %}
2525

26-
{% if site.life_cycle == 'transition-step-3' %}
27-
<meta http-equiv="refresh" content="0; url={{ site.transition_url }}" />
28-
{% endif %}
29-
3026
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
3127
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
3228
<!--[if lt IE 9]>

0 commit comments

Comments
 (0)