Skip to content
Open
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
6 changes: 3 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# frozen_string_literal: true

source "https://rubygems.org"
gem "jekyll", "~> 4.1"
gem "jekyll-feed", "~> 0.15.0"
gem "jekyll-postcss", '~> 0.4.0'
gem "jekyll", "~> 4.2"
gem "jekyll-feed", "~> 0.15.1"
gem "jekyll-postcss", '~> 0.5.0'
gem "jekyll-purgecss"
gem "jekyll-soopr-seo-tag"
gem "jekyll-minifier"
Expand Down
18 changes: 17 additions & 1 deletion bin/publish
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
#!/bin/sh
# This expects to run in your project home directory, e.g. `cookie`
# This deletes & regenerates _site/ which you can `scp -R` to your web server

bundle exec jekyll build
JEKYLL_ENV=production bundle exec jekyll build "$@"

# Hack: assume every *.html (except index) should be moved to a
# subdirectory bearing its name; repeat for blog/ subdirectory
for HTML in $(ls -1 _site/blog/*.html); do
DIR=$(basename $HTML .html)
mkdir "_site/blog/$DIR"
mv $HTML "_site/blog/$DIR/index.html"
done

for HTML in $(ls -1 _site/*.html | grep -v index.html); do
DIR=$(basename $HTML .html)
mkdir "_site/$DIR" >/dev/null 2>&1 # blog/ already exists
mv $HTML "_site/$DIR/index.html"
done
Loading