Skip to content

Commit c1e413f

Browse files
committed
WIP
1 parent 91e6afe commit c1e413f

7 files changed

Lines changed: 37 additions & 30 deletions

File tree

.github/workflows/pages.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,23 +34,22 @@ jobs:
3434
run: sudo apt update
3535
- name: Install dependencies
3636
run: |
37-
sudo apt install libexpat1-dev liblua5.2-dev lua5.2 luarocks libtolua-dev libncurses5-dev libsqlite3-dev libiniparser-dev libcjson-dev libbsd-dev cppcheck shellcheck clang-tools iwyu
37+
sudo apt install libutf8proc-dev libexpat1-dev liblua5.2-dev lua5.2 luarocks libtolua-dev libncurses5-dev libsqlite3-dev libiniparser-dev libcjson-dev libbsd-dev cppcheck shellcheck clang-tools iwyu
3838
luarocks install lunitx --local
3939
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
4040
- name: Checkout repository
41-
uses: actions/checkout@v2
41+
uses: actions/checkout@v3
4242
with:
4343
submodules: true
4444
- name: Build and Test
45-
uses: ashutoshvarma/action-cmake-build@master
45+
uses: threeal/cmake-action@v1.1.0
4646
with:
4747
build-dir: ${{ runner.workspace }}/server/build
48-
build-type: Debug
48+
args: "-DCMAKE_BUILD_TYPE=Debug"
4949
run-test: true
50-
ctest-options: --output-on-failure
5150

5251
- name: Setup Pages
53-
uses: actions/configure-pages@v2
52+
uses: actions/configure-pages@v3
5453
- name: Create demos
5554
run: |
5655
cd stm-jekyll
@@ -61,7 +60,7 @@ jobs:
6160
source: ./stm-jekyll
6261
destination: ./_site
6362
- name: Upload artifact
64-
uses: actions/upload-pages-artifact@v1
63+
uses: actions/upload-pages-artifact@v2
6564

6665
# Deployment job
6766
deploy:
@@ -73,4 +72,4 @@ jobs:
7372
steps:
7473
- name: Deploy to GitHub Pages
7574
id: deployment
76-
uses: actions/deploy-pages@v1
75+
uses: actions/deploy-pages@v2

stm-jekyll/Gemfile

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,9 @@ source "https://rubygems.org"
88
#
99
# This will help ensure the proper Jekyll version is running.
1010
# Happy Jekylling!
11-
# gem "jekyll", "~> 3.8.6"
12-
11+
#gem "jekyll", "~> 4.3.2"
1312
# This is the default theme for new Jekyll sites. You may change this to anything you like.
14-
gem "minima", "~> 2.0"
13+
gem "minima", "~> 2.5"
1514
# gem "architect", "~> 0.2.0"
1615

1716
# If you want to use GitHub Pages, remove the "gem "jekyll"" above and
@@ -21,15 +20,21 @@ gem "github-pages", group: :jekyll_plugins
2120

2221
# If you have any plugins, put them here!
2322
group :jekyll_plugins do
24-
gem "jekyll-feed", "~> 0.6"
23+
gem "jekyll-feed", "~> 0.12"
2524
end
2625

27-
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
26+
# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem
2827
# and associated library.
29-
install_if -> { RUBY_PLATFORM =~ %r!mingw|mswin|java! } do
30-
gem "tzinfo", "~> 1.2"
28+
platforms :mingw, :x64_mingw, :mswin, :jruby do
29+
gem "tzinfo", ">= 1", "< 3"
3130
gem "tzinfo-data"
3231
end
3332

3433
# Performance-booster for watching directories on Windows
35-
gem "wdm", "~> 0.1.0", :install_if => Gem.win_platform?
34+
gem "wdm", "~> 0.1.1", :platforms => [:mingw, :x64_mingw, :mswin]
35+
36+
# Lock `http_parser.rb` gem to `v0.6.x` on JRuby builds since newer versions of the gem
37+
# do not have a Java counterpart.
38+
gem "http_parser.rb", "~> 0.6.0", :platforms => [:jruby]
39+
40+
gem "webrick"

stm-jekyll/_config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ description: >- # this means to ignore newlines until "baseurl:"
2020
baseurl: "/server" # the subpath of your site, e.g. /blog
2121
url: "http://stm2.github.io" # the base hostname & protocol for your site, e.g. http://example.com
2222
github_username: stm2
23+
repository: stm2/server
2324

2425
# Build settings
2526
markdown: kramdown

stm-jekyll/_data/crs/eressea.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ crs:
88
- 1000-demo.cr
99
- 1000-nice.cr
1010
- 1000-foe.cr
11-
date: 2022-09-08
11+
date: 2023-08-30
1212
---
1313
An example with all sorts of stuff that could go on in an Eressea game

stm-jekyll/_data/crs/example.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ name: Demo 001
33
description: A more complex CR
44
crs:
55
- 334-42.cr
6-
date: 2022-09-08
6+
date: 2023-08-30
77
---
88
An example with different types of terrains, ships, lighthouses, and a battle.

stm-jekyll/demos.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ CR:
1212
CRs:
1313
{% endif -%}
1414
{% for cr in demo.crs limit:1 -%}
15-
[{{ cr }}](demos/{{ cr | replace: ".cr", ".html" }})
16-
<span style="font-size:small;"><a href="demos/{{ cr }}">(download)</a></span>
15+
[{{ cr }}]({{ site.baseurl }}/demos/{{ cr | replace: ".cr", ".html" }})
16+
<span style="font-size:small;"><a href="{{ site.baseurl }}/demos/{{ cr }}">(download)</a></span>
1717
{% endfor -%}
1818
{% for cr in demo.crs offset:continue -%}
19-
, [{{ cr }}](demos/{{ cr | replace: ".cr", ".html" }})
20-
<span style="font-size:small;"><a href="demos/{{ cr }}">(download)</a></span>
19+
, [{{ cr }}]({{ site.baseurl }}/demos/{{ cr | replace: ".cr", ".html" }})
20+
<span style="font-size:small;"><a href="{{ site.baseurl }}/demos/{{ cr }}">(download)</a></span>
2121
{% endfor %}
2222
{% if demo.description %}{{ demo.description }}{% endif %}
2323

stm-jekyll/scripts/create_demos.sh

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,19 @@ cp demo/reports/*cr stm-jekyll/_data/crs
1313
cd stm-jekyll
1414

1515
for filename in _data/crs/*md; do
16-
base=${filename%.*}
17-
basebase=$(basename "$base")
18-
php scripts/cr2svg.php --annotate $base.md _demos/$basebase.md
16+
base="${filename%.*}"
17+
basebase="$(basename "$base")"
18+
php scripts/cr2svg.php --annotate "$base.md" "_demos/$basebase.md"
1919
done
2020

2121
for filename in _data/crs/*cr; do
22-
base=${filename%.*}
23-
basebase=$(basename "$base")
24-
if [ -e $base.md ]; then
25-
php scripts/cr2svg.php --md $base.md $base.cr _demos/$basebase.md
22+
base="${filename%.*}"
23+
basebase="$(basename "$base")"
24+
if [ -e "$base.md" ]; then
25+
php scripts/cr2svg.php --md "$base.md" "$base.cr" "_demos/$basebase.md"
2626
else
27-
php scripts/cr2svg.php --html $base.cr _demos/$basebase.md
27+
php scripts/cr2svg.php --html "$base.cr" "_demos/$basebase.md"
2828
fi
29+
cp "$filename" "_demos/$basebase.cr"
2930
done
31+

0 commit comments

Comments
 (0)