bundlerUpdateScript: init and use (#64822)
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
{ stdenv, bundlerEnv, ruby}:
|
||||
{ stdenv, bundlerEnv, ruby, bundlerUpdateScript }:
|
||||
|
||||
let
|
||||
# To update, just run `nix-shell` in this directory.
|
||||
papertrail-env = bundlerEnv rec {
|
||||
name = "papertrail-env";
|
||||
inherit ruby;
|
||||
@@ -18,4 +17,14 @@ in stdenv.mkDerivation {
|
||||
mkdir -p $out/bin
|
||||
ln -s ${papertrail-env}/bin/papertrail $out/bin/papertrail
|
||||
'';
|
||||
|
||||
passthru.updateScript = bundlerUpdateScript "papertrail";
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Command-line client for Papertrail log management service";
|
||||
homepage = http://github.com/papertrail/papertrail-cli/;
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ nicknovitski ];
|
||||
platforms = ruby.meta.platforms;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
{ pkgs ? import <nixpkgs> {} }:
|
||||
|
||||
pkgs.stdenv.mkDerivation {
|
||||
name = "papertrail";
|
||||
src = ./.;
|
||||
|
||||
buildInputs = with pkgs; [
|
||||
bundix
|
||||
bundler
|
||||
ruby
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
truncate --size 0 Gemfile.lock
|
||||
bundle install --path=vendor/bundle
|
||||
rm -rf vendor .bundle
|
||||
bundix
|
||||
'';
|
||||
}
|
||||
Reference in New Issue
Block a user