1 { lib, bundlerApp, ruby
2 , writeShellScriptBin, makeWrapper
3 , withOptionalDependencies ? false
7 rubyWrapper = writeShellScriptBin "ruby" ''
8 if [[ "$#" -eq 2 ]]; then
9 if [[ "''${1##*/}" == "bundle" && "$2" == "install" ]]; then
10 # See https://github.com/NixOS/nixpkgs/issues/58126 for more details.
11 echo 'Skipping "bundle install" as it fails due to the Nix wrapper.'
12 echo 'Please enter the new directory and run the following commands to serve the page:'
13 echo 'nix-shell -p bundler --run "bundle install --gemfile=Gemfile --path vendor/cache"'
14 echo 'nix-shell -p bundler --run "bundle exec jekyll serve"'
16 # The following nearly works:
18 exec ${ruby}/bin/ruby "$@" --gemfile=Gemfile --path=vendor/cache
21 # Else: Don't modify the arguments:
22 exec ${ruby}/bin/ruby "$@"
29 gemdir = if withOptionalDependencies
33 nativeBuildInputs = [ makeWrapper ];
36 wrapProgram $out/bin/jekyll --prefix PATH : ${rubyWrapper}/bin
39 passthru.updateScript = ./update.sh;
42 description = "A blog-aware, static site generator, written in Ruby";
44 Jekyll is a simple, blog-aware, static site generator, written in Ruby.
45 Think of it like a file-based CMS, without all the complexity. Jekyll
46 takes your content, renders Markdown and Liquid templates, and spits out a
47 complete, static website ready to be served by Apache, Nginx or another
48 web server. Jekyll is the engine behind GitHub Pages, which you can use to
49 host sites right from your GitHub repositories.
51 homepage = "https://jekyllrb.com/";
52 #changelog = "https://raw.githubusercontent.com/jekyll/jekyll/v${version}/History.markdown";
53 license = licenses.mit;
54 maintainers = with maintainers; [ ];
55 platforms = platforms.unix;
56 mainProgram = "jekyll";