2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, bundlerEnv, ruby, makeWrapper, bundlerUpdateScript
|
2021-07-20 00:57:43 +00:00
|
|
|
, git, docutils, perl }:
|
2016-02-11 18:49:33 +00:00
|
|
|
|
2017-06-04 14:02:42 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "gollum";
|
2020-03-30 16:20:25 +00:00
|
|
|
# nix-shell -p bundix icu zlib cmake pkg-config openssl
|
2017-06-04 14:02:42 +00:00
|
|
|
version = (import ./gemset.nix).gollum.version;
|
2016-02-11 18:49:33 +00:00
|
|
|
|
2017-06-04 14:02:42 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
2017-06-03 20:50:33 +00:00
|
|
|
|
2021-08-03 12:04:03 +00:00
|
|
|
dontUnpack = true;
|
2017-06-04 14:02:42 +00:00
|
|
|
|
2019-11-09 23:52:53 +00:00
|
|
|
installPhase = let
|
|
|
|
env = bundlerEnv {
|
|
|
|
name = "${pname}-${version}-gems";
|
|
|
|
inherit pname ruby;
|
|
|
|
gemdir = ./.;
|
|
|
|
};
|
|
|
|
in ''
|
2017-06-04 14:02:42 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
makeWrapper ${env}/bin/gollum $out/bin/gollum \
|
2021-07-20 00:57:43 +00:00
|
|
|
--prefix PATH ":" ${lib.makeBinPath [ git docutils perl]}
|
2020-03-30 16:20:25 +00:00
|
|
|
makeWrapper ${env}/bin/gollum-migrate-tags $out/bin/gollum-migrate-tags \
|
2021-01-15 05:42:41 +00:00
|
|
|
--prefix PATH ":" ${lib.makeBinPath [ git ]}
|
2017-06-04 14:02:42 +00:00
|
|
|
'';
|
2016-02-11 18:49:33 +00:00
|
|
|
|
2019-07-22 12:02:47 +00:00
|
|
|
passthru.updateScript = bundlerUpdateScript "gollum";
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-03-30 16:20:25 +00:00
|
|
|
description = "A simple, Git-powered wiki with a sweet API and local frontend";
|
|
|
|
homepage = "https://github.com/gollum/gollum";
|
|
|
|
changelog = "https://github.com/gollum/gollum/blob/v${version}/HISTORY.md";
|
2016-02-11 18:49:33 +00:00
|
|
|
license = licenses.mit;
|
2021-02-27 18:56:10 +00:00
|
|
|
maintainers = with maintainers; [ erictapen jgillich nicknovitski ];
|
2016-02-11 18:49:33 +00:00
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|