Skip to content

Commit

Permalink
[ admin ] Add a makefile to ensure we can build the site locally.
Browse files Browse the repository at this point in the history
  • Loading branch information
jfdm committed Mar 14, 2024
1 parent 752528f commit 307ef78
Show file tree
Hide file tree
Showing 4 changed files with 77 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
*~
*~
*.lock
_site
.sass-cache
.jekyll-cache
.jekyll-metadata
vendor
34 changes: 34 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
source "https://rubygems.org"
# 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 "jekyll", "~> 4.3.1"
# This is the default theme for new Jekyll sites. You may change this to anything you like.
gem "minima", "~> 2.5"

# If you want to use GitHub Pages, remove the "gem "jekyll"" above and
# uncomment the line below. To upgrade, run `bundle update github-pages`.
gem "github-pages", group: :jekyll_plugins
# If you have any plugins, put them here!
group :jekyll_plugins do
gem "jekyll-feed", "~> 0.12"
end

# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem
# and associated library.
platforms :mingw, :x64_mingw, :mswin, :jruby do
gem "tzinfo", ">= 1", "< 3"
gem "tzinfo-data"
end

# Performance-booster for watching directories on Windows
gem "wdm", "~> 0.1.1", :platforms => [:mingw, :x64_mingw, :mswin]

# Lock `http_parser.rb` gem to `v0.6.x` on JRuby builds since newer versions of the gem
# do not have a Java counterpart.
gem "http_parser.rb", "~> 0.6.0", :platforms => [:jruby]
35 changes: 35 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
usage:
echo "The website is based on jekyll and github-pages"
echo ""
echo "We suggest you install them using your system's package or"
echo "if you are using nix invoke a nix shell."
echo ""
echo "We provide the following targets:"
echo ""
echo " make nix-shell"
echo ""
echo "invokes a nix shell with the required dependencies"
echo "to exit run `exit`"
echo ""
echo " make healthcheck"
echo ""
echo "invokes github-pages healthcheck"
echo ""
echo " make build"
echo ""
echo "invokes github-pages build (generating a `_site`)"
echo ""

.PHONY: usage nix-shell healthcheck build

nix-shell:
nix-shell -p jekyll \
rubyPackages.jekyll-feed \
rubyPackages.jekyll-redirect-from \
rubyPackages.github-pages

healthcheck:
github-pages healthcheck

build:
github-pages build
1 change: 1 addition & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ exclude:
- vendor/cache/
- vendor/gems/
- vendor/ruby/
- Makefile

0 comments on commit 307ef78

Please sign in to comment.