nixpkgs-suyu/pkgs/tools/misc/watchexec/default.nix

33 lines
936 B
Nix
Raw Normal View History

2019-11-19 10:20:00 +01:00
{ stdenv, rustPlatform, fetchFromGitHub, CoreServices, installShellFiles }:
2018-02-18 12:46:24 +01:00
2018-08-21 12:00:11 +02:00
rustPlatform.buildRustPackage rec {
2019-05-29 09:36:29 +02:00
pname = "watchexec";
2019-11-19 10:20:00 +01:00
version = "1.12.0";
2018-02-18 12:46:24 +01:00
src = fetchFromGitHub {
2019-05-29 09:36:29 +02:00
owner = pname;
repo = pname;
2018-08-21 12:00:11 +02:00
rev = version;
2019-11-19 10:20:00 +01:00
sha256 = "03s9nsss4895x4lp90y65jajavk8c2nj1jjnmx0vbbwl210ghlv1";
2018-02-18 12:46:24 +01:00
};
cargoSha256 = "0p20d7paiafvl4k9iiazbgq75wk7k42sz2h1y5lalq16f5rp6dbp";
2019-11-19 10:20:00 +01:00
nativeBuildInputs = [ installShellFiles ];
2018-02-18 12:46:24 +01:00
2019-06-20 18:36:11 +02:00
buildInputs = stdenv.lib.optionals stdenv.isDarwin [ CoreServices ];
2018-10-27 18:32:39 +02:00
2019-11-19 10:20:00 +01:00
postInstall = ''
installManPage doc/watchexec.1
installShellCompletion --zsh --name _watchexec completions/zsh
'';
2018-02-18 12:46:24 +01:00
meta = with stdenv.lib; {
description = "Executes commands in response to file modifications";
2018-08-21 12:00:11 +02:00
homepage = https://github.com/watchexec/watchexec;
2018-02-18 12:46:24 +01:00
license = with licenses; [ asl20 ];
maintainers = [ maintainers.michalrus ];
2018-10-27 18:32:39 +02:00
platforms = platforms.linux ++ platforms.darwin;
2018-02-18 12:46:24 +01:00
};
}