567e8dfd8e
This commit was created by a combination of scripts and tools: - an ast-grep script to prefix things in meta with `lib.`, - a modified nixf-diagnose / nixf combination to remove unused `with lib;`, and - regular nixfmt. Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
43 lines
872 B
Nix
43 lines
872 B
Nix
{
|
|
lib,
|
|
stdenv,
|
|
bundlerEnv,
|
|
ruby,
|
|
bundlerUpdateScript,
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "watson-ruby";
|
|
version = (import ./gemset.nix).watson-ruby.version;
|
|
|
|
dontUnpack = true;
|
|
|
|
installPhase =
|
|
let
|
|
env = bundlerEnv {
|
|
name = "watson-ruby-gems-${version}";
|
|
inherit ruby;
|
|
# expects Gemfile, Gemfile.lock and gemset.nix in the same directory
|
|
gemdir = ./.;
|
|
};
|
|
in
|
|
''
|
|
mkdir -p $out/bin
|
|
ln -s ${env}/bin/watson $out/bin/watson
|
|
'';
|
|
|
|
passthru.updateScript = bundlerUpdateScript "watson-ruby";
|
|
|
|
meta = {
|
|
description = "Inline issue manager";
|
|
homepage = "https://goosecode.com/watson/";
|
|
license = with lib.licenses; mit;
|
|
maintainers = with lib.maintainers; [
|
|
robertodr
|
|
nicknovitski
|
|
];
|
|
mainProgram = "watson";
|
|
platforms = lib.platforms.unix;
|
|
};
|
|
}
|