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

Relaunch website with new template and new functionality #208

Draft
wants to merge 35 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
b16ecc9
Add a browser config file
sdruskat Apr 21, 2021
d3e7d2a
Update .gitignore to include more meta files
sdruskat Apr 21, 2021
7fa033b
Update 404 page
sdruskat Apr 21, 2021
83821f3
Update README to reflect new template
sdruskat Apr 21, 2021
1eb8178
Remove Dockerfile
sdruskat Apr 21, 2021
da7c4c6
Remove files with unclear usage
sdruskat Apr 21, 2021
86d5720
Remove unneeded rake templates
sdruskat Apr 21, 2021
4b9bf5f
Remove unneeded Rakefile
sdruskat Apr 21, 2021
0431828
Remove Docker composition file
sdruskat Apr 21, 2021
3855bf7
Remove unneeded index HTML file
sdruskat Apr 21, 2021
4d4c7fb
Update Gem-related files
sdruskat Apr 21, 2021
ecdd7ac
Prepare _drafts folder for relaunch
sdruskat Apr 21, 2021
3db5955
Remove Slack metadata (we're on Rocket.Chat now)
sdruskat Apr 21, 2021
f7fe487
Clean up _includes folder
sdruskat Apr 21, 2021
b9eface
Move JS files to /js/ subfolder
sdruskat Apr 21, 2021
989995e
Create new includes files for new template
sdruskat Apr 21, 2021
707caee
Create new i18n file structure for new template
sdruskat Apr 21, 2021
7c203fb
Create _data folder for new template
sdruskat Apr 21, 2021
64f8855
Overwrite layouts with new template layouts
sdruskat Apr 21, 2021
06e5793
Remove old pages
sdruskat Apr 21, 2021
929b397
Add _pages directory for new template
sdruskat Apr 21, 2021
ee847f0
Restructure assets directory
sdruskat Apr 21, 2021
5374f96
Remove bootstrap template files
sdruskat Apr 21, 2021
9428c2e
Move custom CSS from /css/ to /assets/css/
sdruskat Apr 21, 2021
91d81a2
Remove fonts folder
sdruskat Apr 21, 2021
ea8d61a
Move leaflets JS files to /assets/js/leaflet/
sdruskat Apr 21, 2021
8d4269e
Remove placeholder post
sdruskat Apr 21, 2021
3d913b4
Update post metadata
sdruskat Apr 21, 2021
7c08710
Remove umlaut from file name
sdruskat Apr 21, 2021
7df74fa
Add _sass templates
sdruskat Apr 21, 2021
865f4a7
Update dependencies
sdruskat Apr 21, 2021
7621ec4
Update site config
sdruskat Apr 21, 2021
8105ae5
Fix post language
sdruskat Apr 21, 2021
bd78fb2
Fix links, move JS files
sdruskat Apr 21, 2021
6249ffa
Remove unused menu items
sdruskat Apr 21, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
29 changes: 29 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,32 @@
# Vim
*~
*.sw[p_]

# Sublime Text
*.sublime-project
*.sublime-workspace

# Ruby Gem
*.gem
.bundle
**/vendor/bundle

# Node.js and NPM
node_modules
npm-debug.log*
package-lock.json
codekit-config.json

# macOS
.DS_Store

# Jekyll generated files
.jekyll-cache
.jekyll-metadata
.sass-cache
_asset_bundler_cache
_site

**/_site/**
.idea
.vscode
Expand Down
29 changes: 23 additions & 6 deletions 404.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,30 @@
---
layout: default
layout: single
author_profile: false
namespace: errors
permalink: /404.html
title: "404 - page not found"
permalink_en: /404.html
permalink_de: /404.html
---

# 404
# Not found (404)

**Page not found! :(**
We have changed the way that blog posts are displayed.

Go to [German](/de/) or [English](/en/) page to try again.
If following a link got you here, and you were expecting to find a blog post, you can try to manually add the post language, and change the `.html` suffix to a slash `/`.

Please [add an issue](https://github.com/DE-RSE/de-rse.github.io/issues) if you think this should be fixed. Thanks!
## Examples:

If the URL in your browser is
`https://de-rse.org/blog/2017/03/22/welcome-to-the-de-rse-blog.html`
change it to
`https://de-rse.org/en/blog/2017/03/22/welcome-to-the-de-rse-blog/`.

Similarly,
`https://de-rse.org/blog/2017/03/22/willkommen-beim-de-rse-blog.html`
would become
`https://de-rse.org/de/blog/2017/03/22/willkommen-beim-de-rse-blog/`.

## Other errors

Please [add an issue](https://github.com/DE-RSE/de-rse.github.io/issues) if you think there should be something else here instead of this error page. Thanks!
6 changes: 0 additions & 6 deletions Dockerfile

This file was deleted.

35 changes: 26 additions & 9 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,29 @@
source 'https://rubygems.org'
source "https://rubygems.org"

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
# Fix auto regeneration on Windows
gem 'wdm', '~> 0.1.1' if Gem.win_platform?
# Hello! This is where you manage which Jekyll version is used to run.
# When you want to use a different version, change it below, save the
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
#
# bundle exec jekyll serve
#
# This will help ensure the proper Jekyll version is running.
# Happy Jekylling!

gem 'rake'
# gem "github-pages", group: :jekyll_plugins

gem 'jekyll'
gem "kramdown", ">= 2.3.0"
gem 'jekyll-feed', group: :jekyll_plugins
# To upgrade, run `bundle update`.

gem "jekyll"
gem "minimal-mistakes-jekyll"

# The following plugins are automatically loaded by the theme-gem:
# gem "jekyll-paginate"
# gem "jekyll-sitemap"
# gem "jekyll-gist"
# gem "jekyll-feed"
# gem "jekyll-include-cache"
#
# If you have any other plugins, put them here!
group :jekyll_plugins do
gem "jekyll-multiple-languages-plugin"
end
92 changes: 63 additions & 29 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,67 +4,101 @@ GEM
addressable (2.7.0)
public_suffix (>= 2.0.2, < 5.0)
colorator (1.1.0)
concurrent-ruby (1.1.7)
em-websocket (0.5.1)
concurrent-ruby (1.1.8)
em-websocket (0.5.2)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0.6.0)
eventmachine (1.2.7)
ffi (1.13.1)
faraday (1.4.1)
faraday-excon (~> 1.1)
faraday-net_http (~> 1.0)
faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
ruby2_keywords (>= 0.0.4)
faraday-excon (1.1.0)
faraday-net_http (1.0.1)
faraday-net_http_persistent (1.1.0)
ffi (1.15.0)
forwardable-extended (2.6.0)
http_parser.rb (0.6.0)
i18n (0.9.5)
i18n (1.8.10)
concurrent-ruby (~> 1.0)
jekyll (3.9.0)
jekyll (4.2.0)
addressable (~> 2.4)
colorator (~> 1.0)
em-websocket (~> 0.5)
i18n (~> 0.7)
jekyll-sass-converter (~> 1.0)
i18n (~> 1.0)
jekyll-sass-converter (~> 2.0)
jekyll-watch (~> 2.0)
kramdown (>= 1.17, < 3)
kramdown (~> 2.3)
kramdown-parser-gfm (~> 1.0)
liquid (~> 4.0)
mercenary (~> 0.3.3)
mercenary (~> 0.4.0)
pathutil (~> 0.9)
rouge (>= 1.7, < 4)
rouge (~> 3.0)
safe_yaml (~> 1.0)
jekyll-feed (0.11.0)
jekyll (~> 3.3)
jekyll-sass-converter (1.5.2)
sass (~> 3.4)
terminal-table (~> 2.0)
jekyll-feed (0.15.1)
jekyll (>= 3.7, < 5.0)
jekyll-gist (1.5.0)
octokit (~> 4.2)
jekyll-include-cache (0.2.1)
jekyll (>= 3.7, < 5.0)
jekyll-multiple-languages-plugin (1.7.0)
jekyll (>= 2.0, < 5.0)
jekyll-paginate (1.1.0)
jekyll-sass-converter (2.1.0)
sassc (> 2.0.1, < 3.0)
jekyll-sitemap (1.4.0)
jekyll (>= 3.7, < 5.0)
jekyll-watch (2.2.1)
listen (~> 3.0)
kramdown (2.3.1)
rexml
kramdown-parser-gfm (1.1.0)
kramdown (~> 2.0)
liquid (4.0.3)
listen (3.2.1)
listen (3.5.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
mercenary (0.3.6)
mercenary (0.4.0)
minimal-mistakes-jekyll (4.22.0)
jekyll (>= 3.7, < 5.0)
jekyll-feed (~> 0.1)
jekyll-gist (~> 1.5)
jekyll-include-cache (~> 0.1)
jekyll-paginate (~> 1.1)
jekyll-sitemap (~> 1.3)
multipart-post (2.1.1)
octokit (4.20.0)
faraday (>= 0.9)
sawyer (~> 0.8.0, >= 0.5.3)
pathutil (0.16.2)
forwardable-extended (~> 2.6)
public_suffix (4.0.5)
rake (12.3.3)
public_suffix (4.0.6)
rb-fsevent (0.10.4)
rb-inotify (0.10.1)
ffi (~> 1.0)
rexml (3.2.4)
rouge (3.22.0)
rexml (3.2.5)
rouge (3.26.0)
ruby2_keywords (0.0.4)
safe_yaml (1.0.5)
sass (3.7.4)
sass-listen (~> 4.0.0)
sass-listen (4.0.0)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
sassc (2.4.0)
ffi (~> 1.9)
sawyer (0.8.2)
addressable (>= 2.3.5)
faraday (> 0.8, < 2.0)
terminal-table (2.0.0)
unicode-display_width (~> 1.1, >= 1.1.1)
unicode-display_width (1.7.0)

PLATFORMS
ruby

DEPENDENCIES
jekyll
jekyll-feed
kramdown (>= 2.3.0)
rake
tzinfo-data
jekyll-multiple-languages-plugin
minimal-mistakes-jekyll

BUNDLED WITH
2.1.4
107 changes: 45 additions & 62 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This repository contains the source files for the de-RSE website. Its official hosting URL is <https://www.de-rse.org>.

The site is made to be built with [Jekyll](https://jekyllrb.com/) >= 3.4.1.
The site is made to be built with [Jekyll](https://jekyllrb.com/).

To build, run `bundle install` once (or skip that if you have dependencies already installed and bundler does not work for you) and then `bundle exec jekyll build`.
To preview locally, run `bundle exec jekyll serve --incremental` and browse to <http://localhost:4000>.
Expand All @@ -11,87 +11,70 @@ To include drafts in the preview add the `--drafts` flag.
To see where exactly something breaks or takes long, add the `--verbose` flag.
For all flags use the `--help` flag.

## Contributions

To contribute, please fork, change, test locally (see above) and create a pull request against `master`.

You can use [rake](http://rake.rubyforge.org/) to comfortably create content.

## Create content with `rake`

To create content, run one of the following commands from the repository root. `Rakefile` has been created by [Ellen Gummesson](http://ellengummesson.com/) and is hosted at <https://github.com/gummesson/jekyll-rake-boilerplate>.
## Setup

`rake post["Title"]` creates a new blog post in `_posts`.
This site uses the [Minimal Mistakes Jekyll template](https://github.com/mmistakes/minimal-mistakes) together with the [Multiple Languages Plugin](https://github.com/kurtsson/jekyll-multiple-languages-plugin).
Due to a [bug](https://github.com/kurtsson/jekyll-multiple-languages-plugin/issues/186) in the latter, and due to how the template works, auto-deploying via the GitHub Pages functionality doesn't work.

`rake draft["Title"]` creates a new blog post draft in `_drafts`
Instead, GitHub Actions are used to make it work:

`rake publish` publishes blog post drafts from `_drafts` to `_posts` (interactive CLI-based picking of drafts to publish).
1. The multiple languages plugin is configured so that each language has its own subfolder (`/de/`, `/en/`).
2. The bug makes it impossible to have the default language content both in the root and in the subfolder.
3. Therefore, the root index.html must forward to the default language subfolder.
4. In order to achieve this, a forwarding index.html in the root folder is written during the GitHub Action.
5. The site is then deployed to (and served from) `github-pages`.

`rake page["Title"]` creates a new page (in the root folder).

`rake page["Title","Path/to/folder"]` creates a new page in the respective folder. E.g., to add a page to the English version of the site, use `rake["Title","en"]`.

## YAML headers for pages and posts

The repository contains minimal templates for pages and posts, `_page.txt` and `_post.txt`.
## Contributions

These are used when creating content with `rake` and include the minimal YAML headers needed for the content to show properly.
To contribute, please fork, change, test locally (see above) and create a pull request against `master`.
If you want to contribute bigger changes, please [open an issue](https://github.com/DE-RSE/de-rse.github.io/issues/new/choose) first to discuss your proposed changes.

### Pages
## Contributing content in Markdown

---
title:
layout: default
weight:
---
This site uses the *kramdown* dialect of Markdown.

Pages always have the `default` layout. They must also have a (short) `title` (in double quotes preferably, so it doesn't mess with the YAML), which will be used for the main menu as item texts. `weight` determines the position of the respective menu item in the menu (ascending order).
For help on syntax have a look at:

### Posts
- [quick reference](https://kramdown.gettalong.org/quickref.html)
- or [syntax](https://kramdown.gettalong.org/quickref.html)

---
title:
layout: post
author:
menulang: en
---
## Create a new page

Blog posts will be displayed ordered by publication date on `blog.html`. They always have a `post` layout and must have a `title` and an `author`, both of which will be displayed on the blog index and the post page itself. Publication date is automatically added via `rake publish`. Do not start blog posts with headers (`#`), as the title will be displayed as header.
1. Create template in `_pages`
2. Create content file in `_i18n/<language>/<sectionname>/<pagename>.md
3. in the template Markdown file in `_pages`, add `{% tf <sectionname>/<pagename>.md %}`, which will embed the translated file contents.

`menulang` determines the language of the main menu as displayed on the post page (default: `en`). The language menu items ("Deutsch", "English") link back to the blog index page in the respective language.
## Create a new post

### Redirects
1. Create a new post in the `_posts` directory
2. Provide the key `language` in the YAML metadata (e.g., `language: en`)
3. Only English (`en`) and German (`de`) posts are possible at the moment
4. Posts will be displayed on language-specific blog pages, sorted by publication date

You can also redirect pages to another URL by using the `layout: redirect` and defining a page to redirect to using a [meta refresh](https://en.wikipedia.org/wiki/Meta_refresh).
## Creating a splash page

---
title:
layout: redirect
redirect_page_to: https://xkcd.com
---
Splash pages with feature rows can be used, and content at different places be translated.

## kramdown
- *Excerpt translations* (which replace values for the `excerpt` keys) with a length of > 1 line are translated via a translated file in the `_i18n/<language>/` directory, and a value for the YAML key `excerpt-translation` in the feature row or front matter YAML.
- *Short translations* (1 line, replacing `title` or `btn_label` keys with `title-translation`, `btn_label-translation`) are translated via translation keys in `_i18n/<language>.yml`.

For help on syntax have a look at:
### Example excerpt

- [quick reference](https://kramdown.gettalong.org/quickref.html)
- or [syntax](https://kramdown.gettalong.org/quickref.html)
```yaml
intro:
- excerpt-translation: home/intro-excerpt.md # Long excerpt translations have their own files
feature_row:
- image_path: /assets/images/image.png
alt: "Positions"
title-translation: home.positions-title # Translation key for the positions title
excerpt-translation: home/positions-excerpt.md
url: "/home/positions/"
btn_class: "btn--primary"
btn_label-translation: home.learn-more-button
```

## Map

The map is fed by [mapdata.js](https://github.com/DE-RSE/de-rse.github.io/blob/master/_includes/mapdata.js). Adding someone to the map is as simple as adding a new section in this geoJSON file. Coordinates are available from [http://geojson.io/](http://geojson.io/) . Right now pictures should be 75px high. Inspiration for a nice testimonial can be found at Stephan Druskat's entry.

The map appeared on Dec 6th 2017 on the website. It's based on [leaflet](http://leafletjs.com) v1.2 and [Leaflet.markercluster](https://github.com/Leaflet/Leaflet.markercluster)

## Events

Events are included per year from https://github.com/DE-RSE/de-rse.github.io/tree/master/_includes/events. No language specific remarks in favor of maintainability.

## Converting slack signup domain list

Direct sign up domain list from https://de-rse.slack.com/admin/settings#signup_mode .
Domains get added as people request invites.

```
echo "mpi-cbg.de,mpg.de,tu-dresden.de,crt-dresden.de,hu-berlin.de,tib.eu,dlr.de,gfz-potsdam.de,fmp-berlin.de,rfii.de,uni-goettingen.de,gcdh.de,uni-bielefeld.de,uni-bonn.de,dfg.de,awi.de,geomar.de,uni-muenster.de,helmholtz-hzi.de,tu-berlin.de,pik-potsdam.de,leibniz-fli.de,uni-wuerzburg.de,helmholtz.de,uni-konstanz.de,ac.uk,tu-braunschweig.de,sub.uni-goettingen.de,gwdg.de,fu-berlin.de,hzdr.de" | tr "," "\n" | sort | awk '{print "<li>"$1"</li>" ;}'
```
The map appeared on Dec 6th 2017 on the website. It's based on [leaflet](http://leafletjs.com) v1.2 and [Leaflet.markercluster](https://github.com/Leaflet/Leaflet.markercluster)
Loading