Skip to content

Commit 3aa6c64

Browse files
committed
Use Jekyll templating for building up the site instead of faking multiple pages with JS.
1 parent 850d85f commit 3aa6c64

File tree

20 files changed

+477
-328
lines changed

20 files changed

+477
-328
lines changed

web/.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
_site
2+
.sass-cache
3+
.jekyll-cache
4+
.jekyll-metadata
5+
vendor

web/.nojekyll

Whitespace-only changes.

web/404.html

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
permalink: /404.html
3+
layout: default
4+
---
5+
6+
<style type="text/css" media="screen">
7+
.container {
8+
margin: 10px auto;
9+
max-width: 600px;
10+
text-align: center;
11+
}
12+
h1 {
13+
margin: 30px 0;
14+
font-size: 4em;
15+
line-height: 1;
16+
letter-spacing: -1px;
17+
}
18+
</style>
19+
20+
<div class="container">
21+
<h1>404</h1>
22+
23+
<p><strong>Page not found :(</strong></p>
24+
<p>The requested page could not be found.</p>
25+
</div>

web/Gemfile

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
source "https://rubygems.org"
2+
# Hello! This is where you manage which Jekyll version is used to run.
3+
# When you want to use a different version, change it below, save the
4+
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
5+
#
6+
# bundle exec jekyll serve
7+
#
8+
# This will help ensure the proper Jekyll version is running.
9+
# Happy Jekylling!
10+
gem "jekyll", "~> 4.3.1"
11+
# This is the default theme for new Jekyll sites. You may change this to anything you like.
12+
gem "minima", "~> 2.5"
13+
# If you want to use GitHub Pages, remove the "gem "jekyll"" above and
14+
# uncomment the line below. To upgrade, run `bundle update github-pages`.
15+
# gem "github-pages", group: :jekyll_plugins
16+
# If you have any plugins, put them here!
17+
group :jekyll_plugins do
18+
gem "jekyll-feed", "~> 0.12"
19+
end
20+
21+
# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem
22+
# and associated library.
23+
platforms :mingw, :x64_mingw, :mswin, :jruby do
24+
gem "tzinfo", ">= 1", "< 3"
25+
gem "tzinfo-data"
26+
end
27+
28+
# Performance-booster for watching directories on Windows
29+
gem "wdm", "~> 0.1.1", :platforms => [:mingw, :x64_mingw, :mswin]
30+
31+
# Lock `http_parser.rb` gem to `v0.6.x` on JRuby builds since newer versions of the gem
32+
# do not have a Java counterpart.
33+
gem "http_parser.rb", "~> 0.6.0", :platforms => [:jruby]

web/README.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
PSI/J Web Site
2+
==============
3+
4+
The web site uses Jekyll, which is a Ruby tool for static page
5+
templating/generation. It is the tool used by Github Pages, so
6+
it is readily deployable there *before* running Jekyll.
7+
8+
The web site also builds the documentation with a custom theme
9+
that allows the Sphinx output to be directly integrated into the
10+
main web site.
11+
12+
Building
13+
========
14+
15+
All operations are to be done from the *root directory* of the
16+
PSI/J repository.
17+
18+
1. Install the packages required to build the documentation
19+
(this step is only needed once):
20+
21+
```bash
22+
$ sudo pip install -r requirements-docs.txt
23+
```
24+
25+
2. Install Jekyll (see [Jekyll Installation](https://jekyllrb.com/docs/installation/) - also a one-time operation).
26+
27+
3. Run the build script, which will build the documentation, process
28+
files in the `web` directory, and generate the output in `web-build`:
29+
30+
```bash
31+
$ web/build.sh
32+
```
33+
4. Run the Jekyll server with the script provided:
34+
35+
```bash
36+
$ web/serve.sh
37+
```
38+
39+
You should then see something like:
40+
```
41+
...
42+
Server address: http://127.0.0.1:4000/
43+
Server running... press ctrl-c to stop.
44+
```
45+
46+
You can the point your browser to `http://127.0.0.1:4000` to see the
47+
rendered web site.

web/_config.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# Welcome to Jekyll!
2+
#
3+
# This config file is meant for settings that affect your whole blog, values
4+
# which you are expected to set up once and rarely edit after that. If you find
5+
# yourself editing this file very often, consider using Jekyll's data files
6+
# feature for the data you need to update frequently.
7+
#
8+
# For technical reasons, this file is *NOT* reloaded automatically when you use
9+
# 'bundle exec jekyll serve'. If you change this file, please restart the server process.
10+
#
11+
# If you need help with YAML syntax, here are some quick references for you:
12+
# https://learn-the-web.algonquindesign.ca/topics/markdown-yaml-cheat-sheet/#yaml
13+
# https://learnxinyminutes.com/docs/yaml/
14+
#
15+
# Site settings
16+
# These are used to personalize your new site. If you look in the HTML files,
17+
# you will see them accessed via {{ site.title }}, {{ site.email }}, and so on.
18+
# You can create any custom variable you would like, and they will be accessible
19+
# in the templates via {{ site.myvariable }}.
20+
21+
title: "PSI/J - Python"
22+
23+
description: >- # this means to ignore newlines until "baseurl:"
24+
Write an awesome description for your new site here. You can edit this
25+
line in _config.yml. It will appear in your document head meta (for
26+
Google search results) and in your feed.xml site description.
27+
baseurl: "" # the subpath of your site, e.g. /blog
28+
url: "" # the base hostname & protocol for your site, e.g. http://example.com
29+
twitter_username: jekyllrb
30+
github_username: jekyll
31+
32+
# Build settings
33+
theme: minima
34+
plugins:
35+
- jekyll-feed
36+
37+
# Exclude from processing.
38+
# The following items will not be processed, by default.
39+
# Any item listed under the `exclude:` key here will be automatically added to
40+
# the internal "default list".
41+
#
42+
# Excluded items can be processed by explicitly listing the directories or
43+
# their entries' file path in the `include:` list.
44+
#
45+
# exclude:
46+
# - .sass-cache/
47+
# - .jekyll-cache/
48+
# - gemfiles/
49+
# - Gemfile
50+
# - Gemfile.lock
51+
# - node_modules/
52+
# - vendor/bundle/
53+
# - vendor/cache/
54+
# - vendor/gems/
55+
# - vendor/ruby/
56+
57+
include:
58+
- "**"

web/_includes/footer.html

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<v-footer>
2+
<v-card flat tile class="lighten-1 text-center"
3+
style="margin: auto; padding: 2em 0; background-color: #f5f5f5 !important;">
4+
<v-card-text>
5+
&copy;2021-<script type="application/javascript">document.write(new Date().getFullYear());</script> - <a href="https://exaworks.org">The ExaWorks Project</a>
6+
</v-card-text>
7+
8+
<v-row justify="center">
9+
<v-col justify="center">
10+
<img height="36pt" src="https://exaworks.org/images/llnl.png">
11+
</v-col>
12+
<v-col justify="center">
13+
<img height="36pt" src="https://exaworks.org/images/anl-200.png">
14+
</v-col>
15+
<v-col justify="center">
16+
<img height="36pt" src="https://exaworks.org/images/bnl.png">
17+
</v-col>
18+
<v-col justify="center">
19+
<img height="30pt" src="https://exaworks.org/images/ornl.png"
20+
style="vertical-align: bottom; margin-top: 0.3em">
21+
</v-col>
22+
</v-row>
23+
<v-row justify="center">
24+
<v-col class="text-end">
25+
<img height="20pt"
26+
src="https://science.osti.gov/-/media/_/images/about/resources/logos/png/high-res/RGB_Color-Seal_Green-Mark_SC_Horizontal.png"
27+
style="vertical-align: middle">
28+
</v-col>
29+
<v-col class="text-start">
30+
<span class="psij-font">PSI/J</span> is funded by the U.S. Department of Energy
31+
</v-col>
32+
<v-col class="text-end">
33+
<img height="40pt" src="https://www.ecpannualmeeting.com/images/ecp-horizontal.png">
34+
</v-col>
35+
<v-col class="text-start">
36+
<span class="psij-font">PSI/J</span> is part of the Exascale Computing Project
37+
</v-col>
38+
</v-row>
39+
</v-card>
40+
</v-footer>

web/_includes/head.html

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<link rel="stylesheet" href="/theme-4.css">
2+
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&family=Open+Sans&family=Saira:wght@300;400&family=Nunito+Sans:wght@300;400" rel="stylesheet">
3+
<link href="https://cdn.jsdelivr.net/npm/@mdi/[email protected]/css/materialdesignicons.min.css" rel="stylesheet">
4+
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/vuetify.min.css" rel="stylesheet">
5+
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, minimal-ui">
6+
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/vue.js"></script>
7+
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue-router/2.0.3/vue-router.min.js"></script>
8+
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/vuetify.js"></script>
9+
<script src="https://code.jquery.com/jquery-3.6.0.min.js"
10+
integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
11+
<script src="https://code.jquery.com/jquery-migrate-3.4.0.min.js"></script>
12+
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.4.0/highlight.min.js"></script>
13+
<script src="/lib.js"></script>
14+
<link rel="preconnect" href="https://fonts.googleapis.com">
15+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
16+
<link rel="stylesheet" href="/style.css?id=2">
17+
<link rel="stylesheet"
18+
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.4.0/styles/base16/tender.min.css">
19+
<script src="https://kit.fontawesome.com/0f2ef02e2b.js" crossorigin="anonymous"></script>

web/_includes/menu.html

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<v-app-bar elevation="4" height="48pt" fixed elevate-on-scroll width="100%">
2+
<v-tabs v-model="maintabs">
3+
<v-tab href="index.html" key="index"><div class="psij-font logo">PSI/J</div></v-tab>
4+
<v-tab href="install.html" key="install">Install</v-tab>
5+
<v-tab href="docs" key="docs">Documentation</v-tab>
6+
<v-tab href="resources.html" key="resources">Resources</v-tab>
7+
<v-tab href="about.html" key="about">About</v-tab>
8+
</v-tabs>
9+
10+
<div class="slack-link navbar-link">
11+
<a href="https://join.slack.com/t/exaworks/shared_invite/zt-gttapi1i-GSaiHd8Q0h7uKyZnIqAUwQ"
12+
target="_blank"><i class="fab fa-slack"></i></a>&nbsp;&nbsp;
13+
</div>
14+
<div class="gh-link navbar-link">
15+
<a href="https://github.com/exaworks" target="_blank"><i class="fab fa-github"></i></a>
16+
</div>
17+
</v-app-bar>
18+
19+
<div id="top-spacer"></div>

web/_includes/vueinit.html

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
2+
<script>
3+
var crtpath = null;
4+
v = new Vue({
5+
el: '#psij-app',
6+
vuetify: new Vuetify(),
7+
data: {
8+
themes: ["theme-1", "theme-3"],
9+
maintabs: "{{ page.tab }}"
10+
}
11+
});
12+
13+
hljs.highlightAll();
14+
</script>

0 commit comments

Comments
 (0)