Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add deprecation notice to news and events feeds #1056

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions _includes/filterable_news_list.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,18 @@
{% endif %}
{% endif %}

{% if key_length == 0 or key == "galaxy" %}
{% comment %}
We're on the main page, not a member site.
The `key` is either "galaxy" or empty (`key_length` of 0, renders as "", but doesn't equal "").
{% endcomment %}
{% assign subsite = "eu" %}
{% else %}
{% assign subsite = key %}
{% endif %}
{% assign redirect = "https://galaxyproject.org/" | append: subsite | append: "/news/" %}
{% include page_deprecation_notice.html name="Galaxy News" redirect=redirect %}

<script>
const load = () => {
const urlParams = new URLSearchParams(window.location.search);
Expand Down
10 changes: 10 additions & 0 deletions _includes/page_deprecation_notice.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<div class="alert alert-danger" style="margin-top: 0.5em">
<h3 style="margin-top: 10px">{{ include.name }} is moving!</h3>
<div style="margin-top: 15px">
<p>
You can find new updates at
<a href="{{ include.redirect }}">{{ include.redirect }}</a>.
</p>
<p>This page will no longer be updated.</p>
</div>
</div>
11 changes: 11 additions & 0 deletions _includes/site_deprecation_notice.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<div class="alert alert-danger" style="margin-top: 0.5em">
<h3 style="margin-top: 10px">This site is moving!</h3>
<div style="margin-top: 15px">
<p>
This content will be hosted at
<a href="{{ include.redirect }}">{{ include.redirect }}</a>
going forward. The migration is in progress, so you won't find all the pages there
yet, but that's the place to go for new posts. This site will no longer be updated.
</p>
</div>
</div>
12 changes: 12 additions & 0 deletions _layouts/event_list-galaxy.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@
{% assign key = page_dir[1] | default: page.site %}
{% assign key_length = key | size %}

{% if key_length == 0 or key == "galaxy" %}
{% comment %}
We're on the main page, not a member site.
The `key` is either "galaxy" or empty (`key_length` of 0, renders as "", but doesn't equal "").
{% endcomment %}
{% assign subsite = "eu" %}
{% else %}
{% assign subsite = key %}
{% endif %}
{% assign redirect = "https://galaxyproject.org/" | append: subsite | append: "/events/" %}
{% include page_deprecation_notice.html name="Galaxy Events" redirect=redirect %}

{% assign date_format = site.minima.date_format | default: "%b %-d, %Y" %}
<section class="page-header">
<div class="row">
Expand Down
12 changes: 12 additions & 0 deletions _layouts/event_list.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@
{% assign key = page_dir[1] | default: page.site %}
{% assign key_length = key | size %}

{% if key_length == 0 or key == "galaxy" %}
{% comment %}
We're on the main page, not a member site.
The `key` is either "galaxy" or empty (`key_length` of 0, renders as "", but doesn't equal "").
{% endcomment %}
{% assign subsite = "eu" %}
{% else %}
{% assign subsite = key %}
{% endif %}
{% assign redirect = "https://galaxyproject.org/" | append: subsite | append: "/events/" %}
{% include page_deprecation_notice.html name="Galaxy Events" redirect=redirect %}

{% assign date_format = site.minima.date_format | default: "%b %-d, %Y" %}
<section class="page-header">
<div class="row">
Expand Down
2 changes: 2 additions & 0 deletions belgium/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: home
title: ELIXIR-Belgium
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/belgium/" %}

<div class="row eu-image-box">
<a href="https://www.elixir-belgium.org/" target="_blank">
<img src="/assets/media/ELIXIR_BELGIUM_white_background.png" class="img-responsive eu-image"/>
Expand Down
2 changes: 2 additions & 0 deletions elixir-it/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: home
title: elixir-it
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/elixir-it/" %}

<div class="row eu-image-box">
<a href="https://www.elixir-italy.org/" target="_blank">
<img src="https://raw.githubusercontent.com/Laniakea-elixir-it/resources/master/logos/elixir_italy_white_background.png" class="img-responsive eu-image center"/>
Expand Down
2 changes: 2 additions & 0 deletions erasmusmc/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: home
title: ErasmusMC
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/erasmusmc/" %}

<div class="home">
{% include carousel_before.html pages=4 %}
{% include home_carousel_emc_galaxy.html %}
Expand Down
2 changes: 2 additions & 0 deletions freiburg/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: home
title: Freiburg
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/freiburg/" %}

<div class="home">
{% include carousel_before.html pages=4 %}
{% include home_carousel_galaxy.html %}
Expand Down
2 changes: 2 additions & 0 deletions genouest/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: home
title: GenOuest
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/genouest/" %}

<div class="home">
{% include carousel_before.html pages=4 %}
{% include home_carousel_emc_galaxy.html %}
Expand Down
5 changes: 4 additions & 1 deletion ifb/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
layout: home
title: IFB
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/ifb/" %}

<div class="home">
<div class="row eu-image-box">
<a href="https://elixir-europe.org/about-us/who-we-are/nodes/france" target="_blank">
Expand Down Expand Up @@ -30,4 +33,4 @@ title: IFB

{% include home_news_events.html %}
{% include home_done.html %}
</div>
</div>
2 changes: 2 additions & 0 deletions index.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
layout: home
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/eu/" %}

<div class="home">
{% include home_carousel.html %}
<br>
Expand Down
2 changes: 2 additions & 0 deletions pasteur/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: home
title: Pasteur
---

{% include site_deprecation_notice.html redirect="https://galaxyproject.org/pasteur/" %}

<div style='text-align: center; margin-bottom: 1em'>
<img src="/assets/media/LogoIP-CNRS-C3BI.png" />
</div>
Expand Down