From 7136e0d0a6f61734994c566e2cc72fd75733b873 Mon Sep 17 00:00:00 2001 From: Nick Novitski Date: Mon, 22 Jul 2019 05:02:47 -0700 Subject: bundlerUpdateScript: init and use (#64822) --- pkgs/applications/graphics/image_optim/default.nix | 8 ++++---- pkgs/applications/graphics/image_optim/update.sh | 9 --------- 2 files changed, 4 insertions(+), 13 deletions(-) delete mode 100755 pkgs/applications/graphics/image_optim/update.sh (limited to 'pkgs/applications/graphics') diff --git a/pkgs/applications/graphics/image_optim/default.nix b/pkgs/applications/graphics/image_optim/default.nix index c3dffee3aa8d..385f9825e46f 100644 --- a/pkgs/applications/graphics/image_optim/default.nix +++ b/pkgs/applications/graphics/image_optim/default.nix @@ -1,4 +1,4 @@ -{ lib, bundlerApp, ruby, makeWrapper, +{ lib, bundlerApp, bundlerUpdateScript, makeWrapper, withPngcrush ? true, pngcrush ? null, withPngout ? true, pngout ? null, withAdvpng ? true, advancecomp ? null, @@ -45,8 +45,6 @@ bundlerApp { pname = "image_optim"; gemdir = ./.; - inherit ruby; - exes = [ "image_optim" ]; buildInputs = [ makeWrapper ]; @@ -56,11 +54,13 @@ bundlerApp { --prefix PATH : ${makeBinPath optionalDepsPath} ''; + passthru.updateScript = bundlerUpdateScript "image_optim"; + meta = with lib; { description = "Command line tool and ruby interface to optimize (lossless compress, optionally lossy) jpeg, png, gif and svg images using external utilities (advpng, gifsicle, jhead, jpeg-recompress, jpegoptim, jpegrescan, jpegtran, optipng, pngcrush, pngout, pngquant, svgo)"; homepage = https://github.com/toy/image_optim; license = licenses.mit; - maintainers = with maintainers; [ srghma ]; + maintainers = with maintainers; [ srghma nicknovitski ]; platforms = platforms.all; }; } diff --git a/pkgs/applications/graphics/image_optim/update.sh b/pkgs/applications/graphics/image_optim/update.sh deleted file mode 100755 index 8afd7f90436d..000000000000 --- a/pkgs/applications/graphics/image_optim/update.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env nix-shell -#!nix-shell -i bash -p bundix bundler - -SCRIPT_DIR=$(dirname "$(readlink -f "$BASH_SOURCE")") - -cd $SCRIPT_DIR - -bundle lock --update -bundix -- cgit 1.4.1